/* Yalla Amman — design system (spec §4). Mobile-first; logical properties for RTL/LTR. */

/* Rubik (SIL OFL 1.1, /fonts/OFL.txt), self-hosted so no visitor data goes to a font CDN. Variable weight 400–700. */
@font-face { font-family: "Rubik"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("/fonts/rubik-arabic.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: "Rubik"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("/fonts/rubik-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Rubik"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("/fonts/rubik-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
:root {
  --blue: #175CD3;
  --blue-700: #1249A8;
  --blue-50: #EFF6FF;
  --blue-100: #DCEBFE;
  --accent: #53B1FD;
  --sky: #3F8FD8;
  --navy: #102A56;
  --navy-800: #0B1F42;
  --gray-900: #101828;
  --gray-700: #344054;
  --gray-600: #475467;
  --gray-500: #667085;
  --gray-400: #98A2B3;
  --gray-300: #D0D5DD;
  --gray-200: #EAECF0;
  --gray-100: #F2F4F7;
  --gray-50: #F8FAFC;
  --white: #FFFFFF;
  --success: #027A48;
  --success-50: #ECFDF3;
  --warning: #B54708;
  --warning-50: #FFFAEB;
  --error: #B42318;
  --error-50: #FEF3F2;
  --star: #F5A524;

  --radius-card: 16px;
  --radius-ctl: 10px;
  --radius-pill: 999px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .06);
  --shadow: 0 1px 3px rgba(16, 24, 40, .08), 0 1px 2px rgba(16, 24, 40, .04);
  --shadow-lg: 0 12px 24px -6px rgba(16, 24, 40, .14), 0 4px 8px -4px rgba(16, 24, 40, .06);
  --header-h: 64px;
  --bottom-nav-h: 64px;
  --container: 1280px;
  --font: "Rubik", "Segoe UI", Tahoma, system-ui, -apple-system, "Noto Sans Arabic", sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
/* The hidden attribute must always win over component display rules (e.g. .btn { display: inline-flex }). */
[hidden] { display: none !important; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 12px);
  /* Keep focused/scrolled-to elements clear of the fixed mobile bottom bars (WCAG 2.2 focus not obscured). */
  scroll-padding-bottom: calc(var(--bottom-nav-h) + 24px + env(safe-area-inset-bottom));
}
@media (min-width: 900px) { html { scroll-padding-bottom: 0; } }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  color: var(--gray-700);
  background: var(--gray-50);
  padding-bottom: calc(var(--bottom-nav-h) + env(safe-area-inset-bottom));
  -webkit-font-smoothing: antialiased;
}
body.no-bottom-nav { padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
@media (min-width: 900px) {
  body, body.no-bottom-nav { padding-bottom: 0; }
}
img { max-width: 100%; display: block; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { color: var(--navy); line-height: 1.25; margin: 0 0 .5em; font-weight: 600; }
h1 { font-size: clamp(1.5rem, 1.2rem + 1.4vw, 2.1rem); font-weight: 700; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1rem; }
p { margin: 0 0 1em; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
main:focus { outline: none; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 16px; }
@media (min-width: 768px) { .container { padding-inline: 24px; } }
.narrow { max-width: 760px; }
.page { padding-block: 24px 48px; }
.section { padding-block: 20px; }
.muted { color: var(--gray-500); }
.small { font-size: .875rem; }
.lead { font-size: 1.05rem; color: var(--gray-600); }
.visually-hidden {
  position: absolute !important; 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: 8px; top: -60px; z-index: 100; background: var(--navy); color: #fff; padding: 10px 14px; border-radius: var(--radius-ctl); }
.skip-link:focus { top: 8px; }
.subhead { font-size: 1rem; margin-top: 1.25em; }

/* Icons */
.ic { width: 1.2em; height: 1.2em; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vertical-align: -.22em; }
.ic.star { fill: var(--star); stroke: var(--star); width: 1em; height: 1em; }
[dir="rtl"] .ic.dir { transform: scaleX(-1); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 10px 18px; border-radius: var(--radius-ctl);
  border: 1px solid transparent; font-weight: 500; cursor: pointer; text-decoration: none !important;
  transition: background .15s var(--ease), border-color .15s, box-shadow .15s, transform .1s;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-sm { min-height: 38px; padding: 7px 12px; font-size: .9rem; }
.btn-block { width: 100%; }
.btn-primary { background: var(--blue); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--blue-700); }
.btn-outline { background: #fff; color: var(--gray-700); border-color: var(--gray-300); }
.btn-outline:hover { border-color: var(--blue); color: var(--blue); }
.btn-ghost { background: transparent; color: var(--gray-700); }
.btn-ghost:hover { background: var(--gray-100); }
.btn-light { background: #fff; color: var(--blue); }
.btn-oauth { width: 100%; background: #fff; border-color: var(--gray-300); color: var(--gray-700); }
.btn-oauth:hover { background: var(--gray-50); }
.icon-btn {
  display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid var(--gray-200); background: #fff; color: var(--gray-700); cursor: pointer;
}
.icon-btn-light { background: rgba(255, 255, 255, .92); border-color: transparent; box-shadow: var(--shadow); }
.link-btn { background: none; border: 0; padding: 0; color: var(--blue); cursor: pointer; font: inherit; }
.link-btn:hover { text-decoration: underline; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 40; height: var(--header-h);
  background: rgba(255, 255, 255, .94); backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--gray-200);
}
.header-inner { height: 100%; display: flex; align-items: center; gap: 16px; }
.brand { display: inline-flex; align-items: center; gap: 8px; text-decoration: none !important; flex: none; }
.brand img { width: 30px; height: auto; }
.brand-text { font-weight: 700; font-size: 1.25rem; letter-spacing: -.01em; }
.b-dark { color: var(--navy); }
.b-light { color: var(--sky); }
.main-nav { display: none; gap: 4px; margin-inline-start: 12px; }
.main-nav a { color: var(--gray-600); padding: 8px 12px; border-radius: var(--radius-ctl); font-weight: 500; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.main-nav a:hover { background: var(--gray-100); color: var(--navy); }
.main-nav a.active { color: var(--blue); background: var(--blue-50); }
.main-nav .nav-wain { color: var(--blue); }
.header-actions { margin-inline-start: auto; display: flex; align-items: center; gap: 6px; }
.lang-switch span { font-weight: 600; }
.avatar-btn { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--blue-50); color: var(--blue); }
.hide-sm { display: none !important; }
@media (min-width: 900px) {
  .main-nav { display: flex; }
  .hide-sm { display: inline-flex !important; }
}
@media (max-width: 479px) { .hide-xs { display: none !important; } .lang-switch .ic { display: none; } }

/* Bottom navigation (mobile) */
.bottom-nav {
  position: fixed; inset-inline: 0; bottom: 0; z-index: 45;
  display: grid; grid-template-columns: repeat(5, 1fr);
  height: calc(var(--bottom-nav-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
  background: #fff; border-top: 1px solid var(--gray-200); box-shadow: 0 -4px 16px rgba(16, 24, 40, .05);
}
.bottom-nav a {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  color: var(--gray-500); font-size: .72rem; font-weight: 500; text-decoration: none; min-height: 44px;
}
.bottom-nav a .ic { width: 22px; height: 22px; }
.bottom-nav a.active { color: var(--blue); }
.bn-wain-icon {
  display: grid; place-items: center; width: 40px; height: 40px; margin-top: -18px; border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--accent)); color: #fff; box-shadow: 0 6px 14px rgba(23, 92, 211, .35);
  border: 3px solid #fff;
}
@media (min-width: 900px) { .bottom-nav { display: none; } }

/* Flash / notices */
.flash, .notice {
  display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: var(--radius-ctl);
  background: var(--blue-50); color: var(--navy); border: 1px solid var(--blue-100); margin: 12px 0;
}
.flash span { flex: 1; }
.flash-close { background: none; border: 0; cursor: pointer; color: inherit; padding: 2px; }
.notice-warning { background: var(--warning-50); border-color: #FEDF89; color: #7A2E0E; }
.notice-success { background: var(--success-50); border-color: #ABEFC6; color: #054F31; }
.notice p { margin: 4px 0 8px; }

/* Hero */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background:
    radial-gradient(1200px 400px at 100% -10%, rgba(83, 177, 253, .45), transparent 60%),
    radial-gradient(800px 300px at -10% 110%, rgba(83, 177, 253, .25), transparent 60%),
    linear-gradient(160deg, var(--navy) 0%, #15407F 55%, var(--blue) 100%);
}
.hero::after {
  content: ""; position: absolute; inset-inline: 0; bottom: 0; height: 60px; pointer-events: none;
  background: linear-gradient(transparent, rgba(16, 42, 86, .15));
}
.hero-inner { position: relative; z-index: 1; padding-block: 36px 28px; }
.hero-title { color: #fff; font-size: clamp(1.7rem, 1.2rem + 2.6vw, 3rem); margin-bottom: 20px; }
.hero-title .hero-sub { display: block; font-size: .5em; font-weight: 400; color: #CFE3FF; margin-top: 8px; }
@media (min-width: 900px) { .hero-inner { padding-block: 64px 48px; } }

/* Search */
.search-box, .search-inline { position: relative; }
.search-box { display: flex; align-items: center; background: #fff; border-radius: 14px; box-shadow: var(--shadow-lg); padding: 6px; max-width: 760px; }
.search-box input {
  flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; padding: 10px 8px; font-size: 1rem; color: var(--gray-900);
}
.search-box .search-icon { color: var(--gray-400); margin-inline: 8px 0; width: 22px; height: 22px; }
.search-box .search-submit { flex: none; }
.search-lg input { font-size: 1.05rem; padding-block: 12px; }
@media (max-width: 479px) { .search-box .search-submit { padding-inline: 14px; } }
.suggest-list {
  position: absolute; top: calc(100% + 6px); inset-inline: 0; z-index: 50; margin: 0; padding: 6px; list-style: none;
  background: #fff; border-radius: 12px; box-shadow: var(--shadow-lg); border: 1px solid var(--gray-200); max-height: 60vh; overflow: auto; color: var(--gray-700);
}
.suggest-list li { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 8px; cursor: pointer; }
.suggest-list li[aria-selected="true"], .suggest-list li:hover { background: var(--blue-50); }
.suggest-list .s-icon { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; background: var(--gray-100); color: var(--blue); flex: none; }
.suggest-list .s-text { display: flex; flex-direction: column; min-width: 0; }
.suggest-list .s-label { font-weight: 500; color: var(--gray-900); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.suggest-list .s-hint { font-size: .8rem; color: var(--gray-500); }

/* Chips */
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.chip-scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; margin-inline: -16px; padding-inline: 16px; scroll-padding-inline: 16px; }
.chip-scroll::-webkit-scrollbar { display: none; }
@media (min-width: 768px) { .chip-scroll { margin-inline: 0; padding-inline: 0; } }
.chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 8px 14px; flex: none;
  border-radius: var(--radius-pill); border: 1px solid var(--gray-200); background: #fff; color: var(--gray-700);
  font-weight: 500; font-size: .92rem; text-decoration: none !important; cursor: pointer; white-space: nowrap;
}
.chip:hover { border-color: var(--blue); color: var(--blue); }
.chip.active { background: var(--navy); border-color: var(--navy); color: #fff; }
.chip-sm { min-height: 34px; padding: 5px 12px; font-size: .85rem; }
.chip-sub { margin-top: 8px; }
.chip-hero { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .28); color: #fff; }
.chip-hero:hover { background: rgba(255, 255, 255, .22); color: #fff; border-color: rgba(255, 255, 255, .6); }

/* Section heads */
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.section-head h2 { margin: 0; }
.section-sub { margin: 2px 0 0; color: var(--gray-500); font-size: .92rem; }
.see-all { display: inline-flex; align-items: center; gap: 2px; font-weight: 500; white-space: nowrap; }

/* Category grid */
.category-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 560px) { .category-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 900px) { .category-grid { grid-template-columns: repeat(5, 1fr); } }
@media (min-width: 1200px) { .category-grid { grid-template-columns: repeat(7, 1fr); } }
.category-tile {
  height: 100%; display: flex; flex-direction: column; gap: 8px; padding: 14px; border-radius: var(--radius-card);
  background: #fff; border: 1px solid var(--gray-200); color: var(--gray-700); text-decoration: none !important;
  transition: box-shadow .2s var(--ease), transform .2s var(--ease), border-color .2s;
}
.category-tile:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); border-color: var(--blue-100); }
.category-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: var(--blue-50); color: var(--blue); }
.category-icon .ic { width: 22px; height: 22px; }
.category-name { font-weight: 600; color: var(--navy); line-height: 1.3; }
.category-count { font-size: .8rem; color: var(--gray-500); }

/* Wain Nrooh banner */
.wain-banner {
  display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: var(--radius-card); margin-block: 8px;
  background: linear-gradient(120deg, var(--blue) 0%, #2E7BE6 55%, var(--accent) 100%); color: #fff; text-decoration: none !important;
  box-shadow: var(--shadow-lg); flex-wrap: wrap;
}
.wain-banner > span:nth-child(2) { flex: 1; min-width: 200px; display: flex; flex-direction: column; }
.wain-banner strong { font-size: 1.15rem; }
.wain-banner-icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: rgba(255, 255, 255, .2); }
.wain-banner-icon .ic { width: 26px; height: 26px; }

/* Cards */
.card { background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius-card); box-shadow: var(--shadow-sm); }
.place-card { position: relative; display: flex; flex-direction: column; overflow: hidden; height: 100%; transition: box-shadow .2s var(--ease), transform .2s var(--ease); }
.place-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.place-card:focus-within { box-shadow: 0 0 0 3px var(--accent); }
.card-media { position: relative; aspect-ratio: 16 / 10; overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.ph-icon { position: absolute; inset: 0; display: grid; place-items: center; color: rgba(255, 255, 255, .9); }
.ph-icon .ic { width: 44px; height: 44px; stroke-width: 1.6; }
.ph-icon-lg .ic { width: 72px; height: 72px; }
.ph-0 { background: linear-gradient(135deg, #102A56, #175CD3); }
.ph-1 { background: linear-gradient(135deg, #175CD3, #53B1FD); }
.ph-2 { background: linear-gradient(135deg, #1D3F75, #3F8FD8); }
.ph-3 { background: linear-gradient(135deg, #0E4A6E, #2EA3C9); }
.ph-4 { background: linear-gradient(135deg, #344054, #667085); }
.ph-5 { background: linear-gradient(135deg, #2B3F8C, #6D8FE8); }
.card-media[class*="ph-"]::before, .place-cover[class*="ph-"]::before {
  content: ""; position: absolute; inset: 0; opacity: .12;
  background-image: radial-gradient(circle at 20% 30%, #fff 1.5px, transparent 2px), radial-gradient(circle at 70% 60%, #fff 1.5px, transparent 2px);
  background-size: 28px 28px, 36px 36px;
}
.card-badges { position: absolute; top: 10px; inset-inline-start: 10px; display: flex; gap: 6px; flex-wrap: wrap; }
.badge {
  display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px; border-radius: var(--radius-pill);
  font-size: .75rem; font-weight: 600; line-height: 1.4; white-space: nowrap;
}
.badge .ic { width: 14px; height: 14px; }
.badge-verified { background: #fff; color: var(--blue); }
.card .badge-verified { box-shadow: var(--shadow); }
.badge-sponsored { background: var(--warning-50); color: var(--warning); border: 1px solid #FEDF89; }
.badge-closed { background: var(--error-50); color: var(--error); }
.badge-neutral { background: var(--gray-100); color: var(--gray-600); }
.fav-btn {
  position: absolute; top: 10px; inset-inline-end: 10px; z-index: 2; display: grid; place-items: center;
  width: 38px; height: 38px; border-radius: 50%; background: rgba(255, 255, 255, .95); color: var(--gray-700); box-shadow: var(--shadow);
}
.fav-btn:hover { color: var(--error); }
.card-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.card-title { margin: 0; font-size: 1.02rem; }
.card-title a { color: var(--navy); }
.stretched::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.card-sub { margin: 0; font-size: .85rem; color: var(--gray-500); }
.card-summary { margin: 2px 0 0; font-size: .85rem; display: flex; flex-wrap: wrap; align-items: center; gap: 4px; color: var(--gray-600); }
.card-summary .sep { color: var(--gray-300); }
.rating { display: inline-flex; align-items: center; gap: 3px; color: var(--gray-900); }
.rating b { font-weight: 600; }
.rating-lg { font-size: 1rem; text-decoration: none !important; }
.open-status { margin: 2px 0 0; font-size: .82rem; font-weight: 500; display: flex; align-items: center; gap: 5px; }
.open-status.open { color: var(--success); }
.open-status.soon { color: var(--warning); }
.open-status.closed { color: var(--error); }
.open-status-lg { font-size: .95rem; margin: 8px 0; }
.tag-list { list-style: none; margin: 6px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.tag { display: inline-block; padding: 2px 9px; border-radius: var(--radius-pill); background: var(--gray-100); color: var(--gray-600); font-size: .76rem; font-weight: 500; }
.tag-link { position: relative; z-index: 2; padding: 5px 12px; font-size: .85rem; }
.tag-link:hover { background: var(--blue-50); color: var(--blue); text-decoration: none; }
.card-grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 600px) { .card-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .card-grid { grid-template-columns: repeat(3, 1fr); } }

/* Horizontal scroller */
.scroller { position: relative; }
.scroller-track {
  display: grid; grid-auto-flow: column; grid-auto-columns: 80%; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory;
  scrollbar-width: none; margin-inline: -16px; padding: 4px 16px 12px; scroll-padding-inline: 16px;
}
.scroller-track::-webkit-scrollbar { display: none; }
.scroller-item { scroll-snap-align: start; min-width: 0; }
@media (min-width: 600px) { .scroller-track { grid-auto-columns: 45%; } }
@media (min-width: 900px) { .scroller-track { grid-auto-columns: calc((100% - 42px) / 4); margin-inline: 0; padding-inline: 0; } }
.scroller-btn {
  position: absolute; top: 35%; z-index: 3; display: none; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  border: 1px solid var(--gray-200); background: #fff; box-shadow: var(--shadow-lg); cursor: pointer; color: var(--navy);
}
.scroller-btn.prev { inset-inline-start: -18px; }
.scroller-btn.next { inset-inline-end: -18px; }
@media (min-width: 900px) { .scroller-btn:not([hidden]) { display: grid; } }

/* Near me */
.near-me-prompt { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 16px; border-radius: var(--radius-card); background: #fff; border: 1px dashed var(--gray-300); }
.near-me-prompt p { margin: 0; flex: 1; min-width: 200px; }
.near-me-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--blue-50); color: var(--blue); }

/* Business CTA */
.business-cta {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding: 24px;
  border-radius: var(--radius-card); background: var(--navy); color: #CFE3FF;
}
.business-cta h2 { color: #fff; }
.business-cta p { margin: 0; }
.business-cta-actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* Explore */
.explore { padding-block: 16px 40px; }
.breadcrumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: .88rem; color: var(--gray-500); margin-bottom: 8px; }
.breadcrumbs a { color: var(--gray-600); }
.explore-head h1 { margin-bottom: 4px; }
.explore-head .lead { margin-bottom: 12px; max-width: 70ch; }
.explore-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.search-inline { flex: 1 1 100%; display: flex; align-items: center; background: #fff; border: 1px solid var(--gray-300); border-radius: var(--radius-ctl); padding-inline: 10px; }
.search-inline:focus-within { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-100); }
.search-inline input { flex: 1; min-width: 0; border: 0; outline: 0; padding: 10px 8px; background: transparent; }
.search-inline .search-icon { color: var(--gray-400); }
@media (min-width: 768px) { .search-inline { flex: 1 1 320px; } }
.count-badge { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding-inline: 5px; border-radius: 10px; background: var(--blue); color: #fff; font-size: .72rem; font-weight: 600; }
.sort-select select, .field select, .field input:not([type="checkbox"]):not([type="radio"]) {
  width: 100%; min-height: 44px; padding: 9px 12px; border: 1px solid var(--gray-300); border-radius: var(--radius-ctl); background: #fff; color: var(--gray-900);
}
.sort-select select { width: auto; }
.field select:focus, .field input:focus, .sort-select select:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-100); }
.view-toggle { display: inline-flex; border: 1px solid var(--gray-300); border-radius: var(--radius-ctl); overflow: hidden; background: #fff; }
.view-toggle a { display: inline-flex; align-items: center; gap: 6px; padding: 9px 12px; min-height: 42px; color: var(--gray-600); text-decoration: none; font-weight: 500; }
.view-toggle a.active { background: var(--navy); color: #fff; }
.explore-layout { display: block; margin-top: 16px; }
.explore-main { min-width: 0; }
@media (min-width: 1000px) {
  .explore-layout { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 24px; align-items: start; }
  .filters-toggle { display: none !important; }
}

/* Filters: drawer on mobile, sticky sidebar on desktop */
.filters {
  position: fixed; inset-block: 0; inset-inline-end: 0; z-index: 60; width: min(420px, 100%);
  background: #fff; display: flex; flex-direction: column; transform: translateX(105%); transition: transform .25s var(--ease);
  box-shadow: var(--shadow-lg);
}
[dir="rtl"] .filters { transform: translateX(-105%); }
.filters.open { transform: none !important; }
@media (max-width: 999px) {
  /* Closed drawer must not be reachable by keyboard/screen readers. */
  .filters:not(.open) { visibility: hidden; transition: transform .25s var(--ease), visibility 0s .25s; }
}
.filters-backdrop { position: fixed; inset: 0; z-index: 55; background: rgba(16, 24, 40, .45); }
.filters-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-bottom: 1px solid var(--gray-200); }
.filters-head h2 { margin: 0; }
.filters-body { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 16px; }
.filters-footer { display: flex; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--gray-200); }
.filters-footer .btn { flex: 1; }
@media (min-width: 1000px) {
  .filters { position: sticky; top: calc(var(--header-h) + 16px); inset: auto; z-index: 1; width: auto; transform: none !important;
             max-height: calc(100vh - var(--header-h) - 32px); border: 1px solid var(--gray-200); border-radius: var(--radius-card); box-shadow: var(--shadow-sm); }
  .filters-head .icon-btn { display: none; }
  .filters-footer .btn-primary { display: none; }
  .filters-backdrop { display: none !important; }
}
.field { display: flex; flex-direction: column; gap: 6px; border: 0; padding: 0; margin: 0; min-width: 0; }
.field > label, .field legend { font-weight: 500; color: var(--gray-700); font-size: .92rem; padding: 0; margin-bottom: 6px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.label-row { display: flex; justify-content: space-between; align-items: baseline; }
.hint { font-size: .82rem; color: var(--gray-500); }
.field-error, .form-error { color: var(--error); font-size: .86rem; }
.form-error ul { margin: 0 0 12px; padding-inline-start: 18px; }
.form-error:empty, .validation-summary-valid { display: none; }
.input-validation-error { border-color: var(--error) !important; }
.toggle-list { display: flex; flex-direction: column; gap: 4px; }
.toggle, .check { display: flex; align-items: center; gap: 10px; min-height: 40px; cursor: pointer; }
.toggle input, .check input { width: 20px; height: 20px; accent-color: var(--blue); flex: none; }
.check { align-items: flex-start; margin-bottom: 12px; }
.check input { margin-top: 2px; }
.seg, .check-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.seg label, .check-chips label { position: relative; }
.seg input, .check-chips input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seg span, .check-chips span {
  display: inline-flex; align-items: center; min-height: 36px; padding: 6px 12px; border-radius: var(--radius-pill);
  border: 1px solid var(--gray-300); background: #fff; font-size: .88rem; color: var(--gray-700);
}
.seg input:checked + span, .check-chips input:checked + span { background: var(--navy); border-color: var(--navy); color: #fff; }
.seg input:focus-visible + span, .check-chips input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Results */
.results-head { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.results-count { margin: 0; font-weight: 500; color: var(--gray-600); }
.pill-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.pill { display: inline-flex; align-items: center; gap: 4px; padding: 4px 8px 4px 12px; border-radius: var(--radius-pill); background: var(--blue-50); color: var(--blue); font-size: .85rem; font-weight: 500; }
[dir="rtl"] .pill { padding: 4px 12px 4px 8px; }
.pill .ic { width: 14px; height: 14px; }
.results.loading { opacity: .5; transition: opacity .2s; pointer-events: none; }
.empty-state { text-align: center; padding: 40px 16px; }
.empty-state .search-box { margin: 16px auto; text-align: start; }
.empty-icon { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 20px; background: var(--blue-50); color: var(--blue); margin-bottom: 12px; }
.empty-icon .ic { width: 30px; height: 30px; }
.empty-icon.ok { background: var(--success-50); color: var(--success); }
.empty-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 12px; }
.pagination { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; margin-top: 24px; }
.page-link { display: inline-flex; align-items: center; gap: 4px; min-width: 44px; min-height: 44px; justify-content: center; padding: 8px 12px; border-radius: var(--radius-ctl); border: 1px solid var(--gray-200); background: #fff; color: var(--gray-700); font-weight: 500; }
.page-link.current { background: var(--navy); border-color: var(--navy); color: #fff; }

/* Map */
.map-panel { margin-bottom: 16px; }
.map { height: 55vh; min-height: 320px; border-radius: var(--radius-card); overflow: hidden; background: var(--gray-100); border: 1px solid var(--gray-200); display: grid; place-items: center; }
.map-noscript { padding: 16px; text-align: center; }
@media (min-width: 1000px) {
  .explore.is-map .explore-main { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
  /* Pin columns explicitly: with a sponsored strip there are three children, and auto-placement
     would put sponsored | results on row 1 and push the map to row 2. */
  .explore.is-map .explore-main > * { grid-column: 1; }
  .explore.is-map .map-panel { grid-column: 2; grid-row: 1 / span 2; position: sticky; top: calc(var(--header-h) + 16px); margin: 0; }
  .explore.is-map .map { height: calc(100vh - var(--header-h) - 32px); }
  .explore.is-map .card-grid { grid-template-columns: 1fr; }
}
@media (min-width: 1400px) { .explore.is-map .card-grid { grid-template-columns: repeat(2, 1fr); } }
.map-popup { display: flex; gap: 10px; min-width: 220px; font-family: var(--font); }
.map-popup-img { width: 64px; height: 64px; border-radius: 10px; flex: none; object-fit: cover; }
.map-popup-img.ph { display: grid; place-items: center; color: #fff; }
.map-popup strong { display: block; color: var(--navy); font-size: .95rem; }
.map-popup span { display: block; font-size: .8rem; color: var(--gray-500); }
.map-pin {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50% 50% 50% 4px; transform: rotate(-45deg);
  background: var(--blue); border: 2px solid #fff; box-shadow: var(--shadow-lg); color: #fff;
}
.map-pin .ic { transform: rotate(45deg); width: 16px; height: 16px; }
.marker-cluster-small div, .marker-cluster-medium div, .marker-cluster-large div { background: var(--blue) !important; color: #fff; font-family: var(--font); font-weight: 600; }
.marker-cluster-small, .marker-cluster-medium, .marker-cluster-large { background: rgba(83, 177, 253, .45) !important; }

/* Place page */
.place-cover { position: relative; height: 220px; overflow: hidden; }
.place-cover img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 768px) { .place-cover { height: 340px; } }
.cover-actions { position: absolute; inset-inline: 0; top: 12px; display: flex; justify-content: space-between; z-index: 2; }
.cover-actions-end { display: flex; gap: 8px; }
.place-layout { display: grid; gap: 20px; margin-top: -48px; position: relative; z-index: 3; padding-bottom: 40px; }
@media (min-width: 1000px) { .place-layout { grid-template-columns: minmax(0, 1fr) 340px; align-items: start; } }
.place-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.place-header { padding: 20px; }
.place-header h1 { margin: 4px 0 8px; }
.place-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; margin: 0 0 8px; color: var(--gray-600); }
.place-meta a { color: var(--gray-600); display: inline-flex; align-items: center; gap: 4px; }
.place-meta > span { display: inline-flex; align-items: center; gap: 4px; }
.badge-row { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 4px; }
.place-header .lead { margin: 8px 0 0; }
.quick-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(84px, 1fr)); gap: 8px; }
.qa {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 72px; padding: 10px 6px;
  border-radius: var(--radius-card); border: 1px solid var(--gray-200); background: #fff; color: var(--navy); font-weight: 500; font-size: .85rem;
  text-decoration: none !important; cursor: pointer;
}
.qa .ic { width: 22px; height: 22px; color: var(--blue); }
.qa:hover { border-color: var(--blue); box-shadow: var(--shadow); }
.place-section { padding: 20px; }
.place-section h2 { font-size: 1.15rem; }
.prose { white-space: pre-line; }
.facts { display: grid; grid-template-columns: 1fr; gap: 0; margin: 0; }
.facts > div { display: grid; grid-template-columns: minmax(120px, 40%) 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--gray-100); }
.facts > div:last-child { border-bottom: 0; }
.facts dt { color: var(--gray-500); }
.facts dd { margin: 0; color: var(--gray-900); font-weight: 500; }
.amenities { list-style: none; padding: 0; margin: 12px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.amenities li { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: var(--radius-ctl); background: var(--gray-50); }
.amenities li .amenity-state { margin-inline-start: auto; font-size: .8rem; font-weight: 600; }
.amenities li.yes .ic, .amenities li.yes .amenity-state { color: var(--success); }
.amenities li.no { color: var(--gray-500); }
.hours-table { width: 100%; border-collapse: collapse; }
.hours-table th, .hours-table td { padding: 9px 0; border-bottom: 1px solid var(--gray-100); text-align: start; font-weight: 400; }
.hours-table td { text-align: end; }
.hours-table tr.today th, .hours-table tr.today td { font-weight: 600; color: var(--navy); }
.special-hours { margin: 0 0 12px; padding: 10px 14px; list-style: none; background: var(--warning-50); border-radius: var(--radius-ctl); color: #7A2E0E; }
.mini-map { height: 220px; border-radius: var(--radius-ctl); background: var(--gray-100); display: grid; place-items: center; margin: 12px 0; overflow: hidden; border: 1px solid var(--gray-200); }
.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.contact-list li { display: flex; align-items: center; gap: 10px; min-height: 40px; }
.contact-list .ic { color: var(--gray-500); }
.rating-summary { display: grid; gap: 16px; grid-template-columns: 1fr; margin-bottom: 12px; }
@media (min-width: 560px) { .rating-summary { grid-template-columns: 160px 1fr; align-items: center; } }
.rating-big { display: flex; flex-direction: column; gap: 2px; }
.rating-big b { font-size: 2.4rem; color: var(--navy); line-height: 1; }
.stars, .review-stars { display: inline-flex; gap: 1px; }
.stars .ic, .review-stars .ic { fill: var(--gray-200); stroke: var(--gray-200); width: 16px; height: 16px; }
.stars .on .ic, .review-stars .on .ic { fill: var(--star); stroke: var(--star); }
.dist { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.dist li { display: grid; grid-template-columns: 14px 1fr 28px; gap: 8px; align-items: center; font-size: .85rem; }
.dist .bar { height: 8px; background: var(--gray-100); border-radius: 4px; overflow: hidden; }
.dist .bar span { display: block; height: 100%; background: var(--star); border-radius: 4px; }
.review-list { list-style: none; margin: 0; padding: 0; }
.review { padding: 16px 0; border-top: 1px solid var(--gray-100); }
.review-head { display: flex; align-items: center; gap: 10px; }
.review-head > div { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.avatar { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--blue-100); color: var(--blue-700); font-weight: 600; flex: none; }
.avatar-lg { width: 64px; height: 64px; font-size: 1.6rem; }
.review-text { margin: 10px 0 0; }
.owner-response { margin-top: 10px; padding: 10px 14px; border-inline-start: 3px solid var(--blue); background: var(--gray-50); border-radius: 0 var(--radius-ctl) var(--radius-ctl) 0; }
[dir="rtl"] .owner-response { border-radius: var(--radius-ctl) 0 0 var(--radius-ctl); }
.owner-response p { margin: 4px 0 0; }
.review-foot { display: flex; gap: 16px; margin-top: 8px; }
.place-footer-notes { padding: 4px 4px 0; }
.place-footer-notes a { display: inline-flex; align-items: center; gap: 4px; }
.claim-cta { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; padding: 12px 14px; border-radius: var(--radius-ctl); background: #fff; border: 1px dashed var(--gray-300); color: var(--gray-600); }
.aside-title { font-size: 1.05rem; margin-bottom: 12px; }
.similar-list { display: grid; gap: 14px; }
@media (min-width: 600px) and (max-width: 999px) { .similar-list { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .place-aside { position: sticky; top: calc(var(--header-h) + 16px); margin-top: 60px; } }
.action-bar {
  position: fixed; inset-inline: 0; bottom: 0; z-index: 45; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  gap: 4px; padding: 8px 10px calc(8px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--gray-200);
  box-shadow: 0 -4px 16px rgba(16, 24, 40, .08);
}
.action-bar a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 52px; border-radius: var(--radius-ctl); color: var(--navy); font-size: .78rem; font-weight: 500; text-decoration: none; }
.action-bar a:first-child { background: var(--blue); color: #fff; }
.action-bar .ic { width: 22px; height: 22px; }
@media (min-width: 900px) { .action-bar { display: none; } }

/* Categories & areas pages */
.page-head { margin-bottom: 20px; }
.category-sections { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .category-sections { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .category-sections { grid-template-columns: repeat(3, 1fr); } }
.category-block { padding: 16px; }
.category-block-head { display: flex; gap: 12px; align-items: center; text-decoration: none !important; }
.category-block-head h2 { margin: 0; font-size: 1.05rem; }
.sub-links { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 2px; }
.sub-links a { display: flex; justify-content: space-between; padding: 8px 10px; border-radius: 8px; color: var(--gray-700); }
.sub-links a:hover { background: var(--gray-50); text-decoration: none; color: var(--blue); }
.area-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
.area-tile { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-radius: var(--radius-ctl); background: #fff; border: 1px solid var(--gray-200); color: var(--navy); font-weight: 500; }
.area-tile span:nth-child(2) { flex: 1; }
.area-tile:hover { border-color: var(--blue); text-decoration: none; }

/* Auth */
.auth-page { padding-block: 32px 48px; display: grid; place-items: start center; }
.auth-card { width: 100%; max-width: 440px; padding: 28px 24px; text-align: start; }
.auth-card h1 { font-size: 1.5rem; }
.auth-card form { display: flex; flex-direction: column; gap: 14px; margin-top: 8px; }
.auth-logo { margin-bottom: 12px; }
.auth-switch { text-align: center; margin: 16px 0 0; }
.auth-note { text-align: center; margin: 8px 0 0; }
.divider { display: flex; align-items: center; gap: 12px; color: var(--gray-400); font-size: .85rem; margin: 14px 0 4px; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--gray-200); }
.oauth-form { margin-top: 12px; }
.account-head { display: flex; align-items: center; gap: 16px; }
.account-head h1 { margin: 0; }
.account-head p { margin: 0; }
.prose-page h2 { margin-top: 1.5em; }

/* Footer */
.site-footer { background: #fff; border-top: 1px solid var(--gray-200); margin-top: 24px; padding-top: 32px; }
.footer-grid { display: grid; gap: 24px; grid-template-columns: 1fr 1fr; }
.footer-brand { grid-column: 1 / -1; }
.footer-brand img { width: 96px; height: auto; margin-bottom: 8px; }
.footer-brand p { color: var(--gray-500); max-width: 36ch; }
.footer-grid nav { display: flex; flex-direction: column; gap: 8px; }
.footer-grid h2 { font-size: .85rem; text-transform: uppercase; letter-spacing: .06em; color: var(--gray-500); margin-bottom: 4px; }
[dir="rtl"] .footer-grid h2 { letter-spacing: 0; text-transform: none; }
.footer-grid nav a { color: var(--gray-700); }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding-block: 20px; margin-top: 24px; border-top: 1px solid var(--gray-100); color: var(--gray-500); font-size: .85rem; }
@media (min-width: 900px) {
  .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
  .footer-brand { grid-column: auto; }
}

/* Skeleton loading */
.skeleton { background: linear-gradient(90deg, var(--gray-100) 25%, var(--gray-200) 37%, var(--gray-100) 63%); background-size: 400% 100%; animation: shimmer 1.4s ease infinite; border-radius: var(--radius-card); }
.skeleton-card { height: 290px; }
@keyframes shimmer { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Leaflet RTL fix: map internals must stay LTR */
.leaflet-container { direction: ltr; font-family: var(--font); }

/* ===== Stage 2: contributions ===== */
textarea, .field textarea {
  width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--gray-300); border-radius: var(--radius-ctl);
  background: #fff; color: var(--gray-900); resize: vertical; font: inherit;
}
textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-100); }
.list-create input, .list-settings-form input:not([type="checkbox"]), .share-link input {
  min-height: 42px; padding: 8px 12px; border: 1px solid var(--gray-300); border-radius: var(--radius-ctl); background: #fff; width: 100%;
}
.req { color: var(--error); }
.danger { color: var(--error) !important; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }

/* Save / favorite */
.fav-form { margin: 0; }
.fav-form-card { position: absolute; top: 10px; inset-inline-end: 10px; z-index: 2; }
.fav-form-card .fav-btn { position: static; border: 0; cursor: pointer; }
.fav-form-qa, .fav-form-bar { display: flex; }
.fav-form-qa .qa, .fav-form-bar .bar-btn { flex: 1; width: 100%; }
.is-saved .ic { fill: #E0245E; stroke: #E0245E; }
.is-saved { color: #C01048 !important; }
.bar-btn {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 52px; border-radius: var(--radius-ctl);
  color: var(--navy); font-size: .78rem; font-weight: 500; text-decoration: none; background: none; border: 0; cursor: pointer;
}
.bar-btn .ic { width: 22px; height: 22px; }
.fav-btn.pulse .ic, .qa.pulse .ic, .bar-btn.pulse .ic, .icon-btn.pulse .ic { animation: pop .35s var(--ease); }
@keyframes pop { 50% { transform: scale(1.35); } }

/* List picker on place page */
.list-picker { padding: 0; }
.list-picker > summary { list-style: none; cursor: pointer; padding: 14px 16px; display: flex; align-items: center; gap: 8px; font-weight: 500; color: var(--navy); min-height: 48px; }
.list-picker > summary::-webkit-details-marker { display: none; }
.list-picker[open] > summary { border-bottom: 1px solid var(--gray-100); }
.list-picker-body { padding: 12px 16px 16px; display: grid; gap: 12px; }
.list-picker-items { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.list-picker-items li { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.list-create { display: flex; gap: 8px; }
.list-create input { flex: 1; min-width: 0; }
.list-create-lg { display: grid; gap: 12px; padding: 16px; grid-template-columns: 1fr; margin-top: 16px; }
@media (min-width: 700px) { .list-create-lg { grid-template-columns: 1fr 1fr auto; align-items: end; } }

/* Tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--gray-200); margin-bottom: 20px; overflow-x: auto; }
.tab { display: inline-flex; align-items: center; gap: 6px; padding: 10px 14px; min-height: 44px; color: var(--gray-600); font-weight: 500; border-bottom: 2px solid transparent; margin-bottom: -1px; text-decoration: none !important; white-space: nowrap; }
.tab.active { color: var(--blue); border-bottom-color: var(--blue); }
.count-pill { display: inline-grid; place-items: center; min-width: 22px; height: 20px; padding-inline: 6px; border-radius: 10px; background: var(--gray-100); font-size: .75rem; color: var(--gray-600); }

/* Lists */
.list-grid { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .list-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .list-grid { grid-template-columns: repeat(3, 1fr); } }
.list-tile { display: flex; align-items: center; gap: 12px; padding: 16px; height: 100%; color: var(--gray-700); text-decoration: none !important; }
.list-tile:hover { box-shadow: var(--shadow-lg); }
.list-tile-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--blue-50); color: var(--blue); flex: none; }
.list-tile-body { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.list-tile-body strong { color: var(--navy); }
.list-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; }
.list-settings { padding: 0; margin-bottom: 20px; }
.list-settings > summary { cursor: pointer; padding: 14px 16px; font-weight: 500; display: flex; align-items: center; gap: 8px; list-style: none; }
.list-settings > summary::-webkit-details-marker { display: none; }
.list-settings form { padding: 0 16px 16px; }
.list-settings-form { display: grid; gap: 12px; }
.share-link { display: grid; gap: 4px; }
.list-item-wrap { display: flex; flex-direction: column; gap: 6px; }
.list-remove { align-self: flex-end; }

/* Review compose */
.review-compose { margin: 12px 0 8px; }
.compose-prompt { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 14px 16px; border-radius: var(--radius-ctl); background: var(--gray-50); border: 1px dashed var(--gray-300); }
.compose-prompt p { margin: 0; }
.my-review-status { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.compose-details > summary { list-style: none; display: inline-flex; }
.compose-details > summary::-webkit-details-marker { display: none; }
.compose-details[open] > summary { margin-bottom: 12px; }
.review-form { display: grid; gap: 14px; padding: 16px; border-radius: var(--radius-card); background: var(--gray-50); border: 1px solid var(--gray-200); }
.field-inline input { max-width: 220px; }

/* Star rating input: radios 1..5 in DOM order, highlight via :has() */
.star-input { display: inline-flex; gap: 4px; }
.star-input input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.star-input label { cursor: pointer; padding: 4px; border-radius: 8px; line-height: 0; }
.star-input label .ic { width: 34px; height: 34px; fill: var(--gray-200); stroke: var(--gray-300); stroke-width: 1.5; transition: transform .1s; }
.star-input label:hover .ic { transform: scale(1.1); }
.star-input input:focus-visible + label { outline: 3px solid var(--accent); }
.star-input:has(input:nth-of-type(1):checked) label:nth-of-type(-n+1) .ic,
.star-input:has(input:nth-of-type(2):checked) label:nth-of-type(-n+2) .ic,
.star-input:has(input:nth-of-type(3):checked) label:nth-of-type(-n+3) .ic,
.star-input:has(input:nth-of-type(4):checked) label:nth-of-type(-n+4) .ic,
.star-input:has(input:nth-of-type(5):checked) label:nth-of-type(-n+5) .ic,
.star-input:has(label:nth-of-type(1):hover) label:nth-of-type(-n+1) .ic,
.star-input:has(label:nth-of-type(2):hover) label:nth-of-type(-n+2) .ic,
.star-input:has(label:nth-of-type(3):hover) label:nth-of-type(-n+3) .ic,
.star-input:has(label:nth-of-type(4):hover) label:nth-of-type(-n+4) .ic,
.star-input:has(label:nth-of-type(5):hover) label:nth-of-type(-n+5) .ic { fill: var(--star); stroke: var(--star); }

.helpful-btn { cursor: pointer; }
.helpful-btn.active { background: var(--blue-50); border-color: var(--blue); color: var(--blue); }
.review-foot { align-items: center; flex-wrap: wrap; }
.review-foot form { margin: 0; }

/* Report & suggest */
.report-card, .suggest-card { max-width: 560px; }
.radio-list { display: grid; gap: 6px; }
.radio-row { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 8px 12px; border: 1px solid var(--gray-200); border-radius: var(--radius-ctl); cursor: pointer; background: #fff; }
.radio-row:has(input:checked) { border-color: var(--blue); background: var(--blue-50); }
.radio-row input { width: 18px; height: 18px; accent-color: var(--blue); }
.quote { margin: 0 0 12px; padding: 10px 14px; border-inline-start: 3px solid var(--gray-300); background: var(--gray-50); color: var(--gray-600); border-radius: 6px; }
.similar-links { margin: 6px 0; padding-inline-start: 18px; }

/* Account & history */
.account-links { display: grid; gap: 8px; margin: 16px 0; }
.account-link { display: flex; align-items: center; gap: 12px; padding: 14px 16px; min-height: 52px; color: var(--navy); font-weight: 500; text-decoration: none !important; }
.account-link span { flex: 1; }
.account-link:hover { border-color: var(--blue-100); box-shadow: var(--shadow); }
.stack-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.stack-list.plain { gap: 0; }
.my-review { padding: 16px; }
.my-review-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.row-item { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 12px 0; border-top: 1px solid var(--gray-100); }
.row-item:first-child { border-top: 0; }
.row-item > span:first-child { flex: 1; min-width: 180px; }
.row-note { flex-basis: 100%; }

/* ===== Stage 3: business portal & moderation ===== */
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.55); }
.btn-outline-light:hover { background: rgba(255,255,255,.12); color: #fff; }
.hero-business .business-cta-actions { margin-top: 4px; }
.hero-note { margin: 14px 0 0; color: #CFE3FF; font-size: .92rem; }
.benefit-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .benefit-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .benefit-grid { grid-template-columns: repeat(4, 1fr); } }
.benefit { padding: 18px; }
.benefit h2 { font-size: 1.05rem; margin: 12px 0 6px; }
.benefit p { margin: 0; color: var(--gray-600); }
.claim-search { padding: 20px; }
.claim-search .search-box { box-shadow: none; border: 1px solid var(--gray-300); margin: 12px 0; }
.steps { counter-reset: s; list-style: none; padding: 0; display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 800px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li { counter-increment: s; background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius-card); padding: 16px 16px 16px 56px; position: relative; display: flex; flex-direction: column; gap: 4px; }
[dir="rtl"] .steps li { padding: 16px 56px 16px 16px; }
.steps li::before { content: counter(s); position: absolute; inset-inline-start: 16px; top: 16px; width: 28px; height: 28px; border-radius: 50%; background: var(--blue); color: #fff; display: grid; place-items: center; font-weight: 600; }
.stack-form { display: grid; gap: 12px; }
.match-list { list-style: none; padding: 0; margin: 8px 0; display: grid; gap: 8px; }
.match-list li { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }

/* Business form */
.owner-form-layout { display: block; }
@media (min-width: 1000px) { .owner-form-layout { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 24px; align-items: start; } }
.form-toc { display: none; }
@media (min-width: 1000px) {
  .form-toc { display: flex; flex-direction: column; gap: 2px; position: sticky; top: calc(var(--header-h) + 16px); }
  .form-toc a { padding: 8px 12px; border-radius: 8px; color: var(--gray-600); font-weight: 500; }
  .form-toc a:hover { background: #fff; color: var(--blue); text-decoration: none; }
}
.biz-form { display: grid; gap: 16px; min-width: 0; }
.biz-form .place-section { display: grid; gap: 14px; }
.biz-form h2 { margin: 0; }
.field-row { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .field-row { grid-template-columns: 1fr 1fr; } .field-row.three { grid-template-columns: repeat(3, 1fr); } }
.field-row.three select, .field-row select { min-height: 44px; }
.tri-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
.inline-label { display: flex; flex-direction: column; gap: 4px; font-weight: 500; font-size: .92rem; }
.inline-label input, .field-row select, .special-row input:not([type="checkbox"]), .hours-times input, .decide-form textarea, .inline-form input {
  min-height: 42px; padding: 8px 10px; border: 1px solid var(--gray-300); border-radius: var(--radius-ctl); background: #fff; font: inherit; width: 100%;
}
.subtle-details > summary { cursor: pointer; color: var(--blue); font-weight: 500; margin-bottom: 8px; }
.has-error input, .has-error select, .has-error textarea, .has-error.check { border-color: var(--error) !important; box-shadow: 0 0 0 3px var(--error-50); }
.has-error > label, .has-error > legend { color: var(--error); }
.map-picker { min-height: 56px; border-radius: var(--radius-ctl); background: var(--gray-50); border: 1px dashed var(--gray-300); display: grid; place-items: center; margin-bottom: 8px; }
.map-picker.is-active { height: 300px; border-style: solid; overflow: hidden; }
.hours-editor { display: grid; gap: 6px; }
.hours-row { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--gray-100); }
@media (min-width: 760px) { .hours-row { grid-template-columns: 120px 110px 1fr; } }
.hours-day { font-weight: 600; color: var(--navy); }
.hours-times { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
@media (min-width: 760px) { .hours-times { grid-column: auto; } }
.hours-times input { width: auto; min-width: 116px; }
.second-period { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.hours-row.is-closed .hours-times { opacity: .35; }
.toggle.compact { min-height: 36px; gap: 6px; font-size: .9rem; }
.special-editor { display: grid; gap: 8px; }
.special-row { display: grid; gap: 6px; grid-template-columns: 1fr 1fr; padding: 10px; border: 1px solid var(--gray-200); border-radius: var(--radius-ctl); }
@media (min-width: 900px) { .special-row { grid-template-columns: 150px 100px 110px 110px 1fr 1fr; align-items: center; } }
.form-submit-bar {
  position: sticky; bottom: calc(var(--bottom-nav-h) + env(safe-area-inset-bottom)); z-index: 20; display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; padding: 12px 16px; background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius-card); box-shadow: var(--shadow-lg);
}
@media (min-width: 900px) { .form-submit-bar { bottom: 12px; } }
.form-submit-bar .hint { margin: 0; flex: 1; min-width: 200px; }
[data-attr-container].loading { opacity: .5; }

/* Owner dashboard */
.owned-card { display: flex; align-items: center; gap: 14px; padding: 16px; color: var(--gray-700); text-decoration: none !important; }
.owned-card:hover { box-shadow: var(--shadow-lg); }
.owned-body { flex: 1; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.owned-body strong { color: var(--navy); font-size: 1.05rem; }
.owned-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0; }
.dash-grid { display: grid; gap: 16px; grid-template-columns: 1fr; margin: 16px 0; }
@media (min-width: 900px) { .dash-grid { grid-template-columns: 1fr 1.3fr; } }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin: 0; }
.stats div { background: var(--gray-50); border-radius: var(--radius-ctl); padding: 12px; }
.stats dt { color: var(--gray-500); font-size: .85rem; }
.stats dd { margin: 4px 0 0; font-size: 1.6rem; font-weight: 700; color: var(--navy); }
.big-number { font-size: 1.6rem; color: var(--navy); }
.progress { height: 10px; border-radius: 5px; background: var(--gray-100); overflow: hidden; margin: 4px 0 12px; }
.progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--blue), var(--accent)); border-radius: 5px; }
.checklist { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.checklist li { display: flex; align-items: center; gap: 8px; }
.checklist li .muted { margin-inline-start: auto; }
.checklist li.done { color: var(--gray-500); }
.checklist li.done .ic { color: var(--success); }
.checklist li:not(.done) .ic { color: var(--warning); }
.account-link small { display: block; font-weight: 400; font-size: .82rem; }
.account-link.disabled { opacity: .6; cursor: default; }
.owner-actions { grid-template-columns: 1fr; }
@media (min-width: 800px) { .owner-actions { grid-template-columns: 1fr 1fr; } }
.notif-list .unread { font-weight: 500; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); margin-inline-end: 6px; vertical-align: middle; }

/* Photos */
.upload-form { display: grid; gap: 12px; margin-bottom: 16px; }
.photo-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); margin-bottom: 12px; }
.photo-tile { margin: 0; overflow: hidden; display: flex; flex-direction: column; color: var(--gray-700); text-decoration: none !important; }
.photo-tile img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; background: var(--gray-100); }
.photo-tile figcaption { padding: 10px 12px; display: grid; gap: 8px; }
.photo-actions { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.photo-actions form { margin: 0; }
.photo-actions .icon-btn { width: 38px; height: 38px; }
.alt-edit > summary { list-style: none; }
.alt-edit input { min-height: 38px; padding: 6px 10px; border: 1px solid var(--gray-300); border-radius: 8px; }
.respond > summary { list-style: none; display: inline-flex; margin: 6px 0; }
.respond > summary::-webkit-details-marker, .alt-edit > summary::-webkit-details-marker { display: none; }

/* QR poster (prints on its own page) */
.qr-poster { background: #fff; border: 1px solid var(--gray-200); border-radius: 20px; padding: 32px 24px; text-align: center; max-width: 520px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.qr-logo { width: 140px; height: auto; }
.qr-headline { display: flex; flex-direction: column; gap: 4px; font-size: 1.5rem; margin: 0; }
.qr-code svg { width: 260px; height: 260px; display: block; }
.qr-name { font-weight: 600; color: var(--navy); margin: 0; }
.qr-steps { color: var(--gray-500); margin: 0; font-size: .9rem; }
@media print {
  .site-header, .site-footer, .bottom-nav, .action-bar, .no-print, .flash { display: none !important; }
  body { background: #fff; padding: 0; }
  .qr-poster { border: 0; max-width: none; margin-top: 10mm; }
  .qr-code svg { width: 110mm; height: 110mm; }
}

/* Admin */
.admin-page .tabs { flex-wrap: nowrap; }
.count-pill.hot { background: var(--blue); color: #fff; }
.queue { display: grid; gap: 12px; }
.queue-item { display: flex; gap: 14px; padding: 16px; align-items: flex-start; }
.queue-thumb { width: 120px; height: 80px; object-fit: cover; border-radius: 10px; flex: none; }
.queue-body { flex: 1; min-width: 0; display: grid; gap: 6px; }
.queue-body h2 { font-size: 1.05rem; margin: 0; }
.queue-body p { margin: 0; }
.decide-form { display: grid; gap: 8px; margin-top: 6px; }
.decide-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.inline-form { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.inline-form input { flex: 1; min-width: 200px; width: auto; }
.table-wrap { overflow-x: auto; margin-bottom: 16px; }
.diff-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.diff-table th, .diff-table td { text-align: start; padding: 10px 12px; border-bottom: 1px solid var(--gray-100); vertical-align: top; }
.diff-table thead th { background: var(--gray-50); color: var(--gray-600); font-weight: 600; }
.diff-table td.old { background: #FEF3F2; color: #7A271A; }
.diff-table td.new { background: #ECFDF3; color: #054F31; }

/* Mobile: never let native date/time inputs force the form wider than the screen. */
.biz-form { grid-template-columns: minmax(0, 1fr); }
.biz-form .place-section { grid-template-columns: minmax(0, 1fr); min-width: 0; }
.special-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.special-row input, .hours-times input { min-width: 0; max-width: 100%; }
@media (max-width: 420px) { .hours-times input { flex: 1 1 110px; } .second-period { flex-basis: 100%; } }
@media (min-width: 900px) { .special-row { grid-template-columns: 150px 100px 110px 110px minmax(0, 1fr) minmax(0, 1fr); } }

/* ===== Stage 4: events & offers ===== */
.card-badges.end { inset-inline-start: auto; inset-inline-end: 10px; }
.date-badge {
  position: absolute; bottom: 10px; inset-inline-start: 10px; z-index: 1; display: flex; flex-direction: column; align-items: center;
  min-width: 52px; padding: 4px 8px; border-radius: 12px; background: #fff; box-shadow: var(--shadow); line-height: 1.1;
}
.db-month { font-size: .7rem; font-weight: 600; text-transform: uppercase; color: var(--error); }
.db-day { font-size: 1.35rem; font-weight: 700; color: var(--navy); }
.badge-live { background: var(--success); color: #fff; }
.badge-offer { background: #FFF1E7; color: #B93815; border: 1px solid #FDD6C4; }
.event-when { margin: 2px 0 0; font-size: .88rem; font-weight: 500; color: var(--navy); display: flex; gap: 6px; align-items: center; }
.event-card .card-sub .ic { width: 1em; height: 1em; }
.free-tag { color: var(--success); font-weight: 600; }
.event-card.is-past { opacity: .75; }
.offer-desc { margin: 4px 0 0; font-size: .88rem; color: var(--gray-600); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.offer-until { margin: 6px 0 0; font-size: .82rem; font-weight: 500; color: var(--gray-600); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.offer-until.soon { color: var(--warning); }
.event-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.event-filters select { min-height: 42px; padding: 8px 12px; border: 1px solid var(--gray-300); border-radius: var(--radius-ctl); background: #fff; flex: 1 1 160px; max-width: 260px; }
.eyebrow { display: flex; align-items: center; gap: 6px; margin: 0; color: var(--gray-500); font-size: .88rem; font-weight: 500; }
.event-facts { display: grid; gap: 12px; margin: 12px 0 0; }
.event-facts > div { display: grid; grid-template-columns: 28px 1fr; gap: 10px; align-items: start; }
.event-facts dt { color: var(--blue); padding-top: 2px; }
.event-facts dd { margin: 0; }
.interest { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.interest p { margin: 0; }
.interest-buttons { display: flex; gap: 8px; flex-wrap: wrap; }
.interest-buttons form { margin: 0; }
.offer-detail { overflow: hidden; }
.offer-hero { position: relative; aspect-ratio: 16 / 7; }
.offer-hero img { width: 100%; height: 100%; object-fit: cover; }
.promo-code { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; border: 2px dashed var(--blue-100); background: var(--blue-50); border-radius: var(--radius-ctl); margin: 12px 0; }
.promo-code code { font-size: 1.3rem; font-weight: 700; letter-spacing: .08em; color: var(--navy); }
.mini-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.mini-list li { display: flex; flex-direction: column; gap: 2px; padding-bottom: 10px; border-bottom: 1px solid var(--gray-100); }
.mini-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.offers-strip { border-color: #FDD6C4; background: linear-gradient(180deg, #FFF8F3, #fff 60%); }
.place-section h2 .ic { color: var(--blue); }
.form-thumb { width: 240px; height: auto; border-radius: 10px; margin-bottom: 6px; }

/* ===== Stage 5: Wain Nrooh ===== */
.wain-hero { background: linear-gradient(135deg, var(--navy) 0%, var(--blue) 60%, var(--accent) 130%); color: #fff; padding: 32px 0 28px; }
.wain-hero.compact { padding: 24px 0 20px; }
.wain-hero h1 { color: #fff; margin-bottom: 6px; }
.wain-hero .lead { color: #D6E6FF; }
.wain-title-ar { font-weight: 700; opacity: .9; }
.wain-form { display: grid; gap: 14px; }
.wain-step { padding: 18px; margin: 0; border: 1px solid var(--gray-200); }
.wain-step legend { float: left; width: 100%; font-size: 1.15rem; font-weight: 600; color: var(--navy); margin-bottom: 12px; display: flex; align-items: center; gap: 10px; padding: 0; }
[dir="rtl"] .wain-step legend { float: right; }
.wain-step legend + * { clear: both; }
.step-no { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--blue); color: #fff; font-size: .9rem; flex: none; }
.option-grid { display: grid; gap: 10px; grid-template-columns: repeat(2, minmax(0, 1fr)); clear: both; }
@media (min-width: 640px) { .option-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.option-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.option-card { position: relative; cursor: pointer; }
.option-card input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.option-card > span {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; min-height: 96px; padding: 14px 10px; text-align: center;
  border: 2px solid var(--gray-200); border-radius: var(--radius-card); background: #fff; transition: border-color .15s, background .15s, transform .1s;
}
.option-card > span .ic { width: 28px; height: 28px; color: var(--blue); }
.option-card > span strong { color: var(--navy); font-weight: 600; font-size: .95rem; }
.option-card:hover > span { border-color: var(--accent); }
.option-card input:checked + span { border-color: var(--blue); background: var(--blue-50); }
.option-card input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 2px; }
.option-card input:checked + span::after { content: "✓"; position: absolute; top: 8px; inset-inline-end: 10px; color: var(--blue); font-weight: 700; }
.wain-specific { margin-top: 12px; }
.wain-specific select { min-height: 44px; }
.field-label { font-weight: 500; font-size: .92rem; }
.wain-nav { display: flex; gap: 10px; align-items: center; justify-content: flex-end; flex-wrap: wrap; }
.wain-nav [data-wain-back] { margin-inline-end: auto; }
.wain-progress { height: 6px; border-radius: 3px; background: var(--gray-200); overflow: hidden; }
.wain-progress span { display: block; height: 100%; width: 20%; background: linear-gradient(90deg, var(--blue), var(--accent)); transition: width .25s var(--ease); }
.wain-form:not(.is-wizard) .wain-submit { width: 100%; }
.wain-how { margin-top: 16px; text-align: center; }
.pill-list.light .pill { background: rgba(255,255,255,.16); color: #fff; }
.idea-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; grid-template-columns: 1fr; counter-reset: idea; }
@media (min-width: 700px) { .idea-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .idea-list { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.idea { position: relative; display: flex; flex-direction: column; background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius-card); overflow: hidden; box-shadow: var(--shadow-sm); }
.idea .place-card { border: 0; border-radius: 0; box-shadow: none; flex: none; }
.idea .place-card:hover { transform: none; box-shadow: none; }
.idea-rank { position: absolute; z-index: 3; top: 10px; inset-inline-start: 10px; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--navy); color: #fff; font-weight: 700; box-shadow: var(--shadow); }
.idea .card-badges { inset-inline-start: 50px; }
.why { margin: 0 14px 14px; padding: 10px 12px; border-radius: var(--radius-ctl); background: var(--blue-50); }
.why-label { display: flex; align-items: center; gap: 6px; font-size: .8rem; font-weight: 600; color: var(--blue-700); text-transform: uppercase; letter-spacing: .04em; margin-bottom: 6px; }
[dir="rtl"] .why-label { text-transform: none; letter-spacing: 0; }
.why ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 12px; }
.why li { display: flex; align-items: center; gap: 4px; font-size: .85rem; color: var(--gray-700); }
.why li .ic { width: 14px; height: 14px; color: var(--success); }
.why li.strong { font-weight: 600; color: var(--navy); }

/* Wizard controls stay reachable above the mobile bottom nav. */
.wain-form.is-wizard .wain-nav {
  position: sticky; bottom: calc(var(--bottom-nav-h) + 8px + env(safe-area-inset-bottom)); z-index: 20;
  padding: 10px 12px; background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius-card); box-shadow: var(--shadow-lg);
}
@media (min-width: 900px) { .wain-form.is-wizard .wain-nav { bottom: 12px; } }

/* ---------- Stage 6: analytics & admin ---------- */
.filter-row { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; margin-bottom: 16px; }
.seg-links { display: flex; flex-wrap: wrap; gap: 6px; }
.stat-tiles { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 720px) { .stat-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .stat-tiles { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.stat-tile { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius-card); min-width: 0; }
.stat-label { font-size: .82rem; color: var(--gray-600); }
.stat-value { font-size: 1.6rem; font-weight: 600; color: var(--gray-900); line-height: 1.2; font-variant-numeric: tabular-nums; }
.stat-delta { font-size: .78rem; color: var(--gray-600); }
.stat-delta.up bdi { color: var(--success); font-weight: 600; }
.stat-delta.down bdi { color: var(--error); font-weight: 600; }
.chart { margin: 0; }
.chart-title { font-weight: 600; color: var(--gray-900); margin-bottom: 8px; }
.chart-plot { position: relative; }
.chart-plot svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart-grid { stroke: var(--gray-200); stroke-width: 1; shape-rendering: crispEdges; }
.chart-axis { stroke: var(--gray-400); stroke-width: 1; shape-rendering: crispEdges; }
.chart-tick { fill: var(--gray-500); font-size: 11px; font-family: var(--font); font-variant-numeric: tabular-nums; }
.chart-bar { fill: var(--blue); }
.chart-hit { fill: transparent; }
.chart-col { outline: none; cursor: default; }
.chart-col:hover .chart-hit, .chart-col:focus-visible .chart-hit { fill: var(--blue-50); }
.chart-col:hover .chart-bar, .chart-col:focus-visible .chart-bar { fill: var(--blue-700); }
.chart-tooltip { position: absolute; z-index: 5; pointer-events: none; transform: translate(-50%, calc(-100% - 8px)); white-space: nowrap;
  padding: 6px 10px; border-radius: 8px; background: var(--gray-900); color: #fff; font-size: .8rem; box-shadow: var(--shadow-lg); }
.chart-table { margin-top: 10px; }
.chart-table summary { cursor: pointer; color: var(--blue); font-size: .88rem; }
.chart-table table { margin-top: 8px; }
td.num, th.num { text-align: end; font-variant-numeric: tabular-nums; }
/* Admin shell & shared admin components */
.admin-shell { padding-top: 12px; }
.admin-nav { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: thin; padding: 4px; background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius-card); }
.admin-nav a { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 8px 12px; border-radius: var(--radius-ctl); color: var(--gray-700); font-weight: 500; font-size: .9rem; white-space: nowrap; text-decoration: none; }
.admin-nav a:hover { background: var(--gray-50); color: var(--gray-900); }
.admin-nav a.active { background: var(--blue-50); color: var(--blue-700); }
.admin-nav .ic { width: 16px; height: 16px; }
.admin-page .page-head h1 { overflow-wrap: anywhere; }
.narrow-page { max-width: 880px; }
.admin-filters { display: flex; flex-wrap: wrap; gap: 10px 12px; align-items: flex-end; padding: 14px; margin-bottom: 12px; }
.admin-filters label { display: flex; flex-direction: column; gap: 4px; font-size: .82rem; color: var(--gray-600); min-width: 140px; flex: 0 1 180px; }
.admin-filters label.grow { flex: 1 1 240px; }
.admin-filters input, .admin-filters select { min-height: 40px; }
.admin-table td { vertical-align: middle; }
.nowrap { white-space: nowrap; }
.pager { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 16px 0; }
.badges { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0; }
.badge-muted { background: var(--gray-100); color: var(--gray-500); margin-inline-start: 6px; }
.count-pill.warn { background: var(--warning-50); color: var(--warning); }
.button-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.button-row form { margin: 0; }
.check-row { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 8px 0 12px; }
.check-field { display: flex; align-items: flex-end; }
.admin-form .field { margin-bottom: 14px; }
.admin-form .button-row { margin-top: 8px; }
.danger-zone { margin-top: 16px; padding: 14px 16px; border: 1px dashed #FDA29B; border-radius: var(--radius-card); display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: space-between; }
.danger-zone .hint { margin: 0; }
.dash-grid-2, .dash-grid-3 { grid-template-columns: 1fr; }
@media (min-width: 900px) { .dash-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .dash-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.dash-grid > .card { margin: 0; }
.kv-list, .rank-list, .owner-list, .module-list { list-style: none; margin: 0; padding: 0; }
.kv-list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--gray-100); }
.kv-list li:last-child { border-bottom: 0; }
.kv-grid { display: grid; grid-template-columns: 1fr; column-gap: 32px; }
@media (min-width: 720px) { .kv-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.kv-grid li:last-child { border-bottom: 1px solid var(--gray-100); }
.rank-list { counter-reset: rank; }
.rank-list li { counter-increment: rank; display: flex; gap: 10px; align-items: baseline; padding: 7px 0; border-bottom: 1px solid var(--gray-100); }
.rank-list li::before { content: counter(rank); min-width: 1.4em; color: var(--gray-400); font-variant-numeric: tabular-nums; }
.rank-list li a { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.owner-list li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 16px; padding: 10px 0; border-bottom: 1px solid var(--gray-100); }
.owner-list .inline-form input { min-width: 160px; }
.admin-listing-head { display: flex; gap: 16px; align-items: flex-start; padding: 16px; margin-bottom: 16px; }
.admin-listing-head h1 { font-size: 1.4rem; margin: 0; overflow-wrap: anywhere; }
.admin-listing-head .queue-thumb { flex: none; }
@media (max-width: 600px) { .admin-listing-head { flex-direction: column; } }
.module-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; margin-bottom: 8px; }
.module-row.is-off { background: var(--gray-50); }
.module-row.is-off h2 a { color: var(--gray-500); }
.module-row h2 { font-size: 1rem; margin: 0; }
.module-body { flex: 1; min-width: 0; }
.module-order { display: flex; flex-direction: column; gap: 2px; }
.module-order form, .module-actions form { margin: 0; }
.module-actions { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
@media (max-width: 600px) { .module-row { flex-wrap: wrap; } .module-actions { width: 100%; justify-content: flex-start; } }
.icon-btn[disabled] { opacity: .35; cursor: default; }
.rot-180 { transform: rotate(180deg); }
.export-grid { display: grid; gap: 12px; grid-template-columns: 1fr; margin-bottom: 16px; }
@media (min-width: 720px) { .export-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .export-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.export-card { display: flex; flex-direction: column; gap: 8px; padding: 16px; margin: 0; }
.export-card h2 { font-size: 1rem; margin: 0; }
.export-card .btn { align-self: flex-start; margin-top: auto; }
.attr-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.attr-head h2 { margin: 0; font-size: 1.05rem; }
.compact-form input { min-width: 120px; }
.add-option { margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--gray-200); }
.input-xs { width: 80px !important; min-width: 0 !important; flex: none !important; }
.input-sm { max-width: 160px; }
.tree-indent { color: var(--gray-300); margin-inline-end: 6px; }
.row-child td:first-child { padding-inline-start: 28px; }
.row-parent td:first-child { font-weight: 600; }
.meta-code { display: block; max-width: 320px; font-size: .75rem; color: var(--gray-500); white-space: pre-wrap; overflow-wrap: anywhere; }
.clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 360px; }
.flash.flash-error { background: var(--error-50); color: var(--error); border-color: #FECDCA; }
.sponsored-strip { margin-bottom: 20px; padding: 14px; border: 1px solid #FEDF89; border-radius: var(--radius-card); background: #FFFCF5; }
.sponsored-label { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: .9rem; margin: 0 0 12px; font-weight: 500; }
@media (min-width: 720px) { .sponsored-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.facts dd { overflow-wrap: anywhere; min-width: 0; }
.chart-table { overflow-x: auto; }
/* Scroll wrappers must contain absolutely-positioned descendants (e.g. visually-hidden headers). */
.table-wrap { position: relative; }
.dash-grid > * { min-width: 0; }
@media (min-width: 1100px) { .admin-nav { flex-wrap: wrap; overflow: visible; } }
/* Admin controls outside .field wrappers get the same field styling. */
.admin-page :is(.inline-form, .stack-form, .admin-filters, .decide-form, .compact-form) :is(select, input:not([type="checkbox"]):not([type="radio"]), textarea),
.admin-form :is(select, input:not([type="checkbox"]):not([type="radio"]), textarea) {
  min-height: 40px; padding: 8px 12px; border: 1px solid var(--gray-300); border-radius: var(--radius-ctl); background: #fff; color: var(--gray-900); font: inherit;
}
.admin-page :is(.inline-form, .stack-form, .admin-filters, .compact-form) :is(select, input, textarea):focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-100); }
.admin-page .inline-form select { width: auto; }
.stack-form .btn { justify-self: start; }.admin-link.active { background: var(--blue-50); border-color: var(--blue); color: var(--blue-700); }
@media (max-width: 480px) { .admin-link span { display: none; } }
.btn-danger { background: var(--error); color: #fff; border-color: var(--error); }
.btn-danger:hover { background: #912018; }
.plain-list { margin: 0 0 12px; padding-inline-start: 20px; display: grid; gap: 6px; }
/* WCAG 1.4.1: links inside sentences are underlined, not distinguished by colour alone. */
p a:not(.btn):not(.chip), .hint a, .notice a, .prose-page a, .auth-switch a { text-decoration: underline; text-underline-offset: 2px; }
.chart-col:focus-visible { outline: 2px solid var(--blue); outline-offset: 1px; }
/* The hero search input has no outline of its own; the box shows focus instead (WCAG 2.4.7). */
.search-box:focus-within { box-shadow: var(--shadow-lg), 0 0 0 3px var(--accent); }
.link-form { margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--gray-200); max-width: 520px; }
.notice .grow { flex: 1; min-width: 0; }
.notice .inline-form input { font-size: .85rem; }

/* Homepage hero photo (Amman Citadel at golden hour). The shade keeps white text readable over sky and city. */
.hero-photo { background-color: var(--navy); }
.hero-media, .hero-media img { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-media img { object-fit: cover; object-position: center 62%; }
.hero-photo::before {
  content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background:
    linear-gradient(180deg, rgba(11, 31, 66, .62) 0%, rgba(11, 31, 66, .30) 38%, rgba(11, 31, 66, .18) 60%, rgba(11, 31, 66, .62) 100%);
}
.hero-photo::after { display: none; }
.hero-photo .hero-inner { min-height: 540px; display: flex; flex-direction: column; justify-content: flex-start; padding-block: 40px 32px; }
.hero-photo .hero-title { text-shadow: 0 2px 16px rgba(0, 0, 0, .35); }
.hero-photo .hero-title .hero-sub { color: #F2F6FC; }
.hero-photo .chip-row { margin-top: auto; }
.hero-photo .chip-hero { background: rgba(11, 31, 66, .45); border-color: rgba(255, 255, 255, .35); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.hero-photo .chip-hero:hover { background: rgba(11, 31, 66, .65); }
@media (min-width: 900px) { .hero-photo .hero-inner { min-height: 600px; padding-block: 88px 44px; } }
@media (max-width: 700px) { .hero-media img { object-position: center 78%; } }.hero-media { z-index: 0; }
.hero-photo::before { z-index: 1; }
.hero-photo .hero-inner { z-index: 2; }
/* Hero refinements: lighter shade so the golden light shows; single swipeable chip row on phones. */
.hero-photo::before {
  background: linear-gradient(180deg, rgba(11, 31, 66, .58) 0%, rgba(11, 31, 66, .22) 34%, rgba(11, 31, 66, 0) 55%, rgba(11, 31, 66, .10) 75%, rgba(11, 31, 66, .55) 100%);
}
@media (max-width: 700px) {
  .hero-photo .chip-row {
    flex-wrap: nowrap; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none;
    margin-inline: -16px; padding-inline: 16px; padding-block: 2px 4px;
  }
  .hero-photo .chip-row::-webkit-scrollbar { display: none; }
  .hero-photo .chip-row > * { flex: none; scroll-snap-align: start; }
}@media (max-width: 700px) { .hero-photo .chip-row { margin-inline: 0; padding-inline: 0; } }

/* ---------- Category photos (wwwroot/img/categories) ---------- */
.card-illustration, .cover-illustration, .tile-photo, .block-photo, .head-photo { position: absolute; inset: 0; display: block; z-index: 0; }
.card-illustration img, .cover-illustration img, .tile-photo img, .block-photo img, .head-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* Cards: tinted so a generic category photo never passes for a photo of the place. */
.card-illustration img { filter: saturate(.8); }
.card-illustration::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(16, 42, 86, .10), rgba(16, 42, 86, .38)); }
.illus-icon {
  position: absolute; inset-inline-start: 10px; bottom: 10px; z-index: 1; display: grid; place-items: center; width: 32px; height: 32px;
  border-radius: 50%; background: rgba(11, 31, 66, .6); color: #fff; backdrop-filter: blur(4px);
}
.illus-icon .ic { width: 16px; height: 16px; }
.card-media .card-badges, .card-media .date-badge { z-index: 2; }
.place-cover .cover-actions { position: relative; z-index: 2; }
.cover-illustration::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(11, 31, 66, .35), rgba(11, 31, 66, .1) 40%, rgba(11, 31, 66, .35)); }
.illus-label {
  position: absolute; inset-inline-end: 12px; bottom: 12px; z-index: 2; display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: var(--radius-pill); background: rgba(11, 31, 66, .72); color: #fff; font-size: .78rem;
}
.illus-label .ic { width: 14px; height: 14px; }

/* Homepage tiles with a photo */
.category-tile.has-photo {
  position: relative; overflow: hidden; min-height: 150px; justify-content: flex-end; padding: 12px; border: 0; color: #fff; background: var(--navy);
}
.category-tile.has-photo::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(11, 31, 66, 0) 30%, rgba(11, 31, 66, .82) 100%);
  transition: background .2s var(--ease);
}
.category-tile.has-photo > :not(.tile-photo) { position: relative; z-index: 2; }
.category-tile.has-photo .tile-photo img { transition: transform .35s var(--ease); }
.category-tile.has-photo:hover .tile-photo img { transform: scale(1.05); }
.category-tile.has-photo .category-icon { position: absolute; top: 10px; inset-inline-start: 10px; width: 34px; height: 34px; border-radius: 10px; background: rgba(255, 255, 255, .92); }
.category-tile.has-photo .category-icon .ic { width: 18px; height: 18px; }
.category-tile.has-photo .category-name { color: #fff; text-shadow: 0 1px 6px rgba(0, 0, 0, .4); }
.category-tile.has-photo .category-count { color: #DCE7F7; }
@media (min-width: 900px) { .category-tile.has-photo { min-height: 170px; } }

/* Categories page: photo banner at the top of each block */
.category-block-head.has-photo {
  position: relative; overflow: hidden; margin: -16px -16px 0; padding: 14px 16px; min-height: 130px; align-items: flex-end;
  border-radius: var(--radius-card) var(--radius-card) 0 0; color: #fff;
}
.category-block-head.has-photo::after { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(11, 31, 66, .05) 20%, rgba(11, 31, 66, .8)); }
.category-block-head.has-photo > :not(.block-photo) { position: relative; z-index: 2; }
.category-block-head.has-photo h2 { color: #fff; }
.category-block-head.has-photo .muted { color: #DCE7F7; }
.category-block-head.has-photo .category-icon { background: rgba(255, 255, 255, .92); }

/* Category landing pages: photo banner behind the heading */
.explore-head.has-photo {
  position: relative; overflow: hidden; border-radius: var(--radius-card); padding: 28px 20px 20px; margin-top: 12px; min-height: 190px;
  display: flex; flex-direction: column; justify-content: flex-end; color: #fff; background: var(--navy);
}
.explore-head.has-photo::after { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(11, 31, 66, .15), rgba(11, 31, 66, .82)); }
.explore-head.has-photo > :not(.head-photo) { position: relative; z-index: 2; }
.explore-head.has-photo h1 { color: #fff; text-shadow: 0 2px 12px rgba(0, 0, 0, .35); }
.explore-head.has-photo .lead { color: #EEF3FA; margin-bottom: 0; }
@media (min-width: 900px) { .explore-head.has-photo { min-height: 240px; padding: 40px 32px 28px; } }/* Card placeholders: blurred, darkened category photo behind the category icon. */
.card-illustration img { filter: blur(7px) saturate(.9); transform: scale(1.12); }
.card-illustration::after { background: rgba(16, 42, 86, .42); }
.card-media .card-illustration ~ .ph-icon { z-index: 1; }
.card-media .card-illustration ~ .ph-icon .ic { width: 40px; height: 40px; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .35)); }
/* Wain Nrooh hero photo (friends with a map over Amman at dusk) */
.wain-hero.has-photo { position: relative; overflow: hidden; background: var(--navy); padding: 56px 0 36px; min-height: 360px; display: flex; align-items: flex-end; }
.wain-hero.has-photo > .container { position: relative; z-index: 2; width: 100%; }
.wain-photo { position: absolute; inset: 0; z-index: 0; display: block; }
.wain-photo img { width: 100%; height: 100%; object-fit: cover; object-position: 70% 55%; display: block; }
.wain-hero.has-photo::before {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(90deg, rgba(11, 31, 66, .78) 0%, rgba(11, 31, 66, .45) 45%, rgba(11, 31, 66, .05) 75%),
              linear-gradient(0deg, rgba(11, 31, 66, .55), rgba(11, 31, 66, 0) 45%);
}
[dir="rtl"] .wain-hero.has-photo::before {
  background: linear-gradient(270deg, rgba(11, 31, 66, .78) 0%, rgba(11, 31, 66, .45) 45%, rgba(11, 31, 66, .05) 75%),
              linear-gradient(0deg, rgba(11, 31, 66, .55), rgba(11, 31, 66, 0) 45%);
}
.wain-hero.has-photo h1 { text-shadow: 0 2px 14px rgba(0, 0, 0, .35); }
.wain-hero.has-photo .lead { color: #EEF3FA; max-width: 46ch; }
.wain-hero.has-photo .chip-hero { background: rgba(11, 31, 66, .45); border-color: rgba(255, 255, 255, .35); backdrop-filter: blur(6px); }
@media (min-width: 900px) { .wain-hero.has-photo { min-height: 420px; padding: 80px 0 44px; } }
@media (max-width: 700px) {
  .wain-hero.has-photo { min-height: 440px; }
  .wain-photo img { object-position: 72% 50%; }
  .wain-hero.has-photo::before, [dir="rtl"] .wain-hero.has-photo::before { background: linear-gradient(180deg, rgba(11, 31, 66, .55) 0%, rgba(11, 31, 66, .15) 40%, rgba(11, 31, 66, .75) 100%); }
}
.offer-hero { overflow: hidden; }@media (max-width: 700px) {
  .wain-photo img { object-position: 60% 45%; }
  .wain-hero.has-photo::before, [dir="rtl"] .wain-hero.has-photo::before { background: linear-gradient(180deg, rgba(11, 31, 66, .35) 0%, rgba(11, 31, 66, .05) 35%, rgba(11, 31, 66, .72) 78%, rgba(11, 31, 66, .85) 100%); }
}

/* Whole-card links (.stretched::after covers its card): the card must be the positioning box, or the link
   covers the whole page and swallows clicks on tabs and filters. */
.event-card, .offer-card { position: relative; display: flex; flex-direction: column; overflow: hidden; height: 100%; transition: box-shadow .2s var(--ease), transform .2s var(--ease); }
.event-card:hover, .offer-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.card:has(> * .stretched), .card:has(.stretched) { position: relative; }
/* ---------- Place photo gallery ---------- */
.gallery-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 640px) { .gallery-grid { grid-template-columns: repeat(3, 1fr); } }
.gallery-grid.single { grid-template-columns: 1fr; }
.gallery-grid.pair { grid-template-columns: repeat(2, 1fr); }
.gallery-thumb { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 12px; background: var(--gray-100); }
.gallery-grid.single .gallery-thumb { aspect-ratio: 16 / 9; }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s var(--ease); }
.gallery-thumb:hover img { transform: scale(1.04); }
.gallery-thumb:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }
.gallery-more {
  position: absolute; inset: 0; display: grid; place-items: center; background: rgba(11, 31, 66, .55);
  color: #fff; font-size: 1.6rem; font-weight: 700;
}

/* Full-screen viewer */
.lightbox { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(8, 17, 36, .96); color: #fff; }
.lightbox::backdrop { background: rgba(8, 17, 36, .96); }
.lightbox[open] { display: grid; place-items: center; }
.lightbox-figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 10px; max-width: min(1400px, 100vw - 32px); pointer-events: none; }
.lightbox-img { max-width: 100%; max-height: calc(100dvh - 120px); object-fit: contain; border-radius: 8px; pointer-events: auto; }
.lightbox-caption { font-size: .92rem; color: #DCE7F7; text-align: center; padding: 0 56px; }
.lightbox-count { color: #9FB3D1; margin-inline-start: 8px; font-variant-numeric: tabular-nums; }
.lightbox-btn {
  position: absolute; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(255, 255, 255, .14); color: #fff; transition: background .15s;
}
.lightbox-btn:hover { background: rgba(255, 255, 255, .28); }
.lightbox-btn:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.lightbox-btn .ic { width: 22px; height: 22px; }
.lightbox-close { top: 14px; inset-inline-end: 14px; }
.lightbox-prev { top: 50%; transform: translateY(-50%); inset-inline-start: 14px; }
.lightbox-next { top: 50%; transform: translateY(-50%); inset-inline-end: 14px; }
.lightbox.single .lightbox-prev, .lightbox.single .lightbox-next { display: none; }
@media (max-width: 640px) { .lightbox-prev, .lightbox-next { top: auto; bottom: 16px; transform: none; } }@media (min-width: 641px) { .lightbox-figure { max-width: min(1400px, 100vw - 150px); } }
/* Owner form: breathing room between category-specific fields */
[data-attr-container] > .field + .field { margin-top: 16px; }
[data-attr-container] .field > fieldset.field { margin: 0; }

/* ---------- Platform photos, set 2: page banners, seasonal banners, Wain ideas, For Business, empty states, sign-in ---------- */

/* Events / Offers page banner (same treatment as category landing pages) */
.page-head.photo-head {
  position: relative; overflow: hidden; border-radius: var(--radius-card); padding: 28px 20px 20px; margin-top: 4px; min-height: 190px;
  display: flex; flex-direction: column; justify-content: flex-end; background: var(--navy);
}
.page-head.photo-head::after { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(11, 31, 66, .10), rgba(11, 31, 66, .80)); }
.page-head.photo-head > :not(.head-photo) { position: relative; z-index: 2; }
.page-head.photo-head h1 { color: #fff; text-shadow: 0 2px 12px rgba(0, 0, 0, .35); margin-bottom: 4px; }
.page-head.photo-head .lead { color: #EEF3FA; margin-bottom: 0; }
@media (min-width: 900px) { .page-head.photo-head { min-height: 250px; padding: 40px 32px 28px; } }

/* Homepage seasonal modules: photo strip with the title on top */
.season-banner {
  position: relative; overflow: hidden; border-radius: var(--radius-card); background: var(--navy); margin-bottom: 16px;
  min-height: 150px; padding: 20px; display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap;
}
.season-photo { position: absolute; inset: 0; z-index: 0; display: block; }
.season-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 55%; display: block; }
.season-banner::after { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(11, 31, 66, 0) 20%, rgba(11, 31, 66, .78) 100%); }
.season-banner > :not(.season-photo) { position: relative; z-index: 2; }
.season-text h2 { color: #fff; margin: 0; text-shadow: 0 2px 12px rgba(0, 0, 0, .4); }
.season-text p { color: #EEF3FA; margin: 4px 0 0; }
@media (min-width: 900px) { .season-banner { min-height: 210px; padding: 28px 32px; } }

/* Wain Nrooh quick-idea photo cards */
.idea-strip { margin-top: 20px; }
.idea-strip-title { font-size: 1.15rem; margin-bottom: 10px; }
.idea-cards {
  list-style: none; margin: 0; padding: 0 0 4px; display: grid; gap: 12px;
  grid-auto-flow: column; grid-auto-columns: minmax(200px, 62vw); overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
}
.idea-cards::-webkit-scrollbar { display: none; }
.idea-cards > li { scroll-snap-align: start; }
@media (min-width: 700px) { .idea-cards { grid-auto-flow: row; grid-template-columns: repeat(5, 1fr); overflow: visible; } }
.idea-card {
  position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 14px; background: var(--navy);
  color: #fff; text-decoration: none; transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
.idea-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.idea-card:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }
.idea-photo { position: absolute; inset: 0; display: block; }
.idea-photo img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s var(--ease); }
.idea-card:hover .idea-photo img { transform: scale(1.05); }
.idea-card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(11, 31, 66, 0) 45%, rgba(11, 31, 66, .85) 100%); }
.idea-label { position: absolute; inset-inline: 12px; bottom: 10px; z-index: 1; display: flex; align-items: center; gap: 6px; font-weight: 600; line-height: 1.25; }
.idea-label .ic { width: 18px; height: 18px; flex: none; }

/* For Business hero photo: shade on the text side; mirrored in Arabic so the owner stays opposite the text */
.hero-business.has-photo { background: var(--navy); }
.business-photo { position: absolute; inset: 0; z-index: 0; display: block; }
.business-photo img { width: 100%; height: 100%; object-fit: cover; object-position: 70% 40%; display: block; }
[dir="rtl"] .business-photo img { transform: scaleX(-1); }
.hero-business.has-photo::before {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(90deg, rgba(11, 31, 66, .88) 0%, rgba(11, 31, 66, .62) 45%, rgba(11, 31, 66, .10) 80%);
}
[dir="rtl"] .hero-business.has-photo::before { background: linear-gradient(270deg, rgba(11, 31, 66, .88) 0%, rgba(11, 31, 66, .62) 45%, rgba(11, 31, 66, .10) 80%); }
.hero-business.has-photo::after { display: none; }
.hero-business.has-photo .hero-inner { z-index: 2; min-height: 380px; display: flex; flex-direction: column; justify-content: center; }
.hero-business.has-photo .hero-title { max-width: 22ch; text-shadow: 0 2px 14px rgba(0, 0, 0, .35); }
@media (min-width: 900px) { .hero-business.has-photo .hero-inner { min-height: 460px; } }
@media (max-width: 700px) {
  .business-photo img { object-position: 78% 40%; }
  .hero-business.has-photo::before, [dir="rtl"] .hero-business.has-photo::before { background: linear-gradient(180deg, rgba(11, 31, 66, .55) 0%, rgba(11, 31, 66, .70) 55%, rgba(11, 31, 66, .90) 100%); }
}

/* "How it works" steps with illustrations */
.steps.steps-illustrated li { padding: 0 0 18px; overflow: hidden; gap: 6px; }
[dir="rtl"] .steps.steps-illustrated li { padding: 0 0 18px; }
.steps-illustrated .step-art { display: block; background: #fff; border-bottom: 1px solid var(--gray-100); }
.steps-illustrated .step-art img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: contain; display: block; }
.steps-illustrated li::before { position: static; margin: 14px 16px 2px; flex: none; }
.steps-illustrated li strong, .steps-illustrated li > span { padding-inline: 16px; }

/* Empty states: illustration instead of the round icon */
.empty-art { display: block; width: min(300px, 72vw); margin: 0 auto 8px; }
.empty-art img { width: 100%; height: auto; display: block; mix-blend-mode: multiply; }

/* Sign-in / register: Amman photo beside the form on wide screens */
.auth-photo { display: none; }
@media (min-width: 960px) {
  .auth-page.auth-split { grid-template-columns: minmax(0, 460px) minmax(0, 440px); justify-content: center; align-items: stretch; gap: 0; }
  .auth-split .auth-photo { display: block; border-radius: var(--radius-card) 0 0 var(--radius-card); overflow: hidden; background: var(--navy); }
  [dir="rtl"] .auth-split .auth-photo { border-radius: 0 var(--radius-card) var(--radius-card) 0; }
  .auth-split .auth-photo img { width: 100%; height: 100%; min-height: 560px; object-fit: cover; display: block; }
  .auth-split .auth-card { border-start-start-radius: 0; border-end-start-radius: 0; max-width: none; padding: 36px 32px; }
}

/* Footer credit */
.footer-credit a { color: var(--gray-700, #344054); font-weight: 600; text-decoration: none; }
.footer-credit a:hover { color: var(--blue); text-decoration: underline; }
/* ---------- Installable app: footer button, phone banner, iPhone instructions ---------- */
.footer-install { margin-top: 12px; }
.install-banner {
  position: fixed; inset-inline: 12px; bottom: calc(76px + env(safe-area-inset-bottom)); z-index: 60;
  display: flex; align-items: center; gap: 10px; padding: 10px 10px 10px 12px;
  background: #fff; border: 1px solid var(--gray-200); border-radius: 16px; box-shadow: var(--shadow-lg);
  animation: install-in .3s var(--ease);
}
.install-banner[hidden] { display: none; }
.install-banner img { border-radius: 10px; flex: none; }
.install-banner-text { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.3; }
.install-banner-text strong { font-size: .92rem; }
.install-banner-text span { font-size: .8rem; color: var(--gray-500); }
.install-banner .btn { flex: none; }
.install-dismiss { flex: none; width: 36px; height: 36px; }
body.no-bottom-nav .install-banner { bottom: calc(12px + env(safe-area-inset-bottom)); }
@keyframes install-in { from { transform: translateY(12px); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .install-banner { animation: none; } }

.install-ios { width: min(420px, calc(100vw - 32px)); border: 0; border-radius: 20px; padding: 24px 20px 20px; text-align: center; box-shadow: var(--shadow-lg); }
.install-ios::backdrop { background: rgba(11, 31, 66, .55); }
.install-ios img { border-radius: 14px; margin: 0 auto 8px; display: block; }
.install-ios h2 { font-size: 1.15rem; margin: 0 0 12px; }
.install-ios ol { text-align: start; margin: 0 0 18px; padding-inline-start: 22px; display: grid; gap: 10px; }
.install-ios-close { position: absolute; top: 10px; inset-inline-end: 10px; }
.ios-share { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: var(--blue-50); color: var(--blue); vertical-align: middle; }
.ios-share .ic { width: 18px; height: 18px; }
/* Room under the page so the install banner never hides the last items */
body.has-install-banner main { padding-bottom: 104px; }
html:has(body.has-install-banner) { scroll-padding-bottom: calc(var(--bottom-nav-h) + 120px + env(safe-area-inset-bottom)); }
