/* Business directory on the home page (rezbee.app). Tokens follow index.html. */

.discover { --d-line: #E3EBED; --d-muted: #6B7A7E; --d-card: #FFFFFF; background: #F4F8F9; }

/* Head: dark band that carries the H1 and the search */
.discover-head {
  position: relative;
  padding: 44px 2rem 54px;
  background: #1A1A2E url('/assets/background-v2-1920.jpg') center center / cover no-repeat;
  background-image: image-set(url('/assets/optimized/background-v2-1920.webp') type('image/webp'), url('/assets/background-v2-1920.jpg') type('image/jpeg'));
  background-attachment: fixed; /* the photo stays put while the page scrolls over it (same on #download and the footer) */
  color: #fff;
  overflow: hidden;
}
/* `background-attachment: fixed` is janky or ignored on touch devices */
@media (hover: none), (max-width: 900px) {
  .discover-head { background-attachment: scroll; }
}
@media (max-width: 900px) {
  .discover-head { background-image: image-set(url('/assets/optimized/background-v2-960.webp') type('image/webp'), url('/assets/background-v2-1920.jpg') type('image/jpeg')); }
}
.discover-head::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(26,26,46,.88), rgba(26,26,46,.94)); }
.discover-head > * { position: relative; }
.discover-head .section-container { max-width: 1200px; margin: 0 auto; }
.discover-eyebrow { font-size: .78rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: #7FE3EF; margin: 0 0 .6rem; }
.discover-head h1 { font-size: clamp(1.5rem, 3.3vw, 2.5rem); font-weight: 800; line-height: 1.2; margin: 0 0 1rem; }
/* One CTA line under the H1; same grey as the other dark sections' text. The band is centred. */
.discover-head .section-container { text-align: center; }
.discover-lead { font-size: 1.25rem; color: rgba(255, 255, 255, 0.8); max-width: 640px; margin: 0 auto 1.6rem; line-height: 1.5; font-weight: 500; }
@media (min-width: 769px) { .discover-head h1 { white-space: nowrap; } }
.discover-head h1 span { background: linear-gradient(135deg, #00BCD4, #7FE3EF); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }

/* Tools: search box + chips on the light background, above the rows */
.discover-tools { max-width: 1200px; margin: 0 auto; padding: 0 2rem; position: relative; z-index: 1; }
/* One white panel that overlaps the band: the search field on top, the filter rows under a divider */
.discover-tools-inner { margin-top: -26px; background: #fff; border: 1px solid var(--d-line); border-radius: 18px; box-shadow: 0 14px 34px rgba(10,30,35,.10); padding: .85rem .9rem .75rem; }
.discover-searchbox { background: #F1F5F6; border-radius: 999px; }
.discover-searchbox:focus-within { background: #fff; box-shadow: 0 0 0 2px #00BCD4; }
.discover-search { display: flex; align-items: center; gap: .6rem; padding: .3rem .35rem .3rem 1.05rem; }
.discover-search i { color: #00BCD4; font-size: 1rem; }
.discover-search input { flex: 1; min-width: 0; border: 0; outline: 0; font: inherit; font-size: 1.02rem; color: #1A1A2E; padding: .55rem 0; background: transparent; }
.discover-search input::placeholder { color: #8A9699; }
.discover-search input::-webkit-search-cancel-button { -webkit-appearance: none; }
.discover-clear { border: 0; background: #DDE5E8; color: #1A1A2E; width: 30px; height: 30px; border-radius: 50%; font-size: 1.1rem; cursor: pointer; display: grid; place-items: center; }
.discover-clear:hover { background: #DDE7E9; }
.discover-search-btn { border: 0; background: #00BCD4; color: #fff; font-weight: 700; font-size: .9rem; padding: .58rem 1.1rem; border-radius: 999px; cursor: pointer; white-space: nowrap; transition: background .15s; }
.discover-search-btn:hover { background: #00A5BA; }

.discover-map-link { display: inline-flex; align-items: center; gap: .45rem; margin: .55rem 0 .1rem; font-size: .86rem; font-weight: 700; color: #00747F; text-decoration: none; }
.discover-map-link:hover { text-decoration: underline; }
.discover-map-link .fa-map-location-dot { color: #00BCD4; }
.discover-filters { display: flex; flex-direction: column; gap: .15rem; margin-top: .7rem; padding-top: .55rem; border-top: 1px solid #EEF2F3; }
.d-filter-row { display: flex; align-items: center; gap: .7rem; min-width: 0; }
.d-filter-label { flex: none; width: 66px; font-size: .68rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--d-muted); }
.discover-chips { flex: 1; min-width: 0; display: flex; gap: .4rem; overflow-x: auto; padding: .3rem 0; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.discover-chips::-webkit-scrollbar { display: none; }
.d-chip { flex: none; border: 0; background: #F1F5F6; color: #1A1A2E; font: inherit; font-size: .82rem; font-weight: 600; padding: .4rem .8rem; border-radius: 999px; cursor: pointer; white-space: nowrap; transition: background .15s, color .15s; display: inline-flex; align-items: center; gap: .35rem; }
.d-chip:hover { background: #E3EBED; }
.d-chip.active { background: #1A1A2E; color: #fff; }
.d-chip .d-chip-count { font-size: .7rem; color: var(--d-muted); }
.d-chip.active .d-chip-count { color: #CFEFF4; }
.d-chip i { font-size: .76rem; color: #00BCD4; }
.d-chip.active i { color: #7FE3EF; }

/* Hero actions: sign in (cyan; or the signed-in customer's name → /randevularim) and add a business (white, so the two read as different things). The app download lives in the navbar. */
.discover-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .7rem; margin-top: .2rem; }
.d-hero-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem; min-height: 52px;
  padding: .8rem 1.5rem; border-radius: 999px; background: #00BCD4; color: #fff;
  font-weight: 800; font-size: 1.02rem; text-decoration: none; white-space: nowrap;
  box-shadow: 0 10px 28px rgba(0, 188, 212, .32);
  transition: background .18s, transform .2s, box-shadow .2s;
}
.d-hero-btn i { font-size: 1.1rem; }
.d-hero-btn:hover, .d-hero-btn:focus-visible { background: #00A5BA; color: #fff; transform: translateY(-2px); box-shadow: 0 14px 34px rgba(0, 188, 212, .42); outline: none; }
.d-hero-btn:active { transform: none; }
.d-hero-btn.is-user span { max-width: 190px; overflow: hidden; text-overflow: ellipsis; }
.d-hero-btn-plain, .d-hero-btn-plain:hover, .d-hero-btn-plain:focus-visible { box-shadow: none; }
/* "İşletmemi ekle": plain text beside the capsule, no background or shadow. */
.d-hero-btn-business { background: transparent; color: #fff; box-shadow: none; padding-left: .9rem; padding-right: .9rem; }
.d-hero-btn-business:hover, .d-hero-btn-business:focus-visible { background: transparent; color: #fff; box-shadow: none; transform: none; text-decoration: underline; text-underline-offset: 4px; }

/* Search mode: everything above the box folds away (see directory.js) */
.discover.is-searching .discover-head { display: none; }
.discover.is-searching .discover-tools { padding-top: 1rem; }
.discover.is-searching .discover-tools-inner { margin-top: 0; }
.discover.is-searching .discover-body { padding-top: 1rem; }
.discover-head h1 { scroll-margin-top: 0; }

/* Body: the rows */
.discover-body { max-width: 1200px; margin: 0 auto; padding: 1.6rem 2rem 1rem; }
.d-state { padding: 2.4rem 1rem; text-align: center; color: var(--d-muted); font-size: .98rem; }
.d-state .rw-btn, .d-state .d-btn { margin-top: .9rem; }
.d-btn { display: inline-flex; align-items: center; gap: .45rem; border: 0; background: #00BCD4; color: #0B2A30; font: inherit; font-weight: 700; padding: .62rem 1.1rem; border-radius: 999px; cursor: pointer; text-decoration: none; }
.d-btn.secondary { background: #fff; color: #00747F; border: 1px solid var(--d-line); }

.d-row { margin: 0 0 1.6rem; }
.d-row-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-bottom: .7rem; }
.d-row-head h2 { font-size: 1.22rem; font-weight: 800; color: #1A1A2E; margin: 0; display: flex; align-items: center; gap: .5rem; }
.d-row-head h2 .d-row-icon { width: 34px; height: 34px; border-radius: 10px; background: #E0F7FA; color: #00BCD4; display: inline-grid; place-items: center; font-size: .95rem; flex: none; }
.d-row-head p { margin: .15rem 0 0; font-size: .86rem; color: var(--d-muted); }
.d-row-foot { display: flex; justify-content: flex-end; margin: -.35rem 0 0; }
.d-row-all { font: inherit; font-size: .9rem; font-weight: 700; color: #00747F; background: none; border: 0; padding: .3rem 0; cursor: pointer; text-decoration: none; white-space: nowrap; display: inline-flex; align-items: center; gap: .4rem; }
.d-row-all:hover { text-decoration: underline; }
/* Opened out: the strip becomes a grid of every card */
.d-row.expanded .d-track { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); overflow: visible; scroll-snap-type: none; margin: 0; padding: .25rem 0 .6rem; }
.d-row.expanded .d-track > li { width: auto; }
.d-row.expanded .d-row-nav { display: none; }
@media (max-width: 520px) { .d-row.expanded .d-track { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; } .d-row.expanded .d-track > li { width: auto; max-width: none; } }
.d-row-nav { display: none; gap: .35rem; flex: none; }
@media (hover: hover) and (min-width: 700px) { .d-row-nav { display: inline-flex; } }
.d-row-nav button { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--d-line); background: #fff; color: #1A1A2E; cursor: pointer; display: grid; place-items: center; font-size: .85rem; transition: background .15s; }
.d-row-nav button:hover { background: #EAF8FB; }
.d-row-nav button:disabled { opacity: .35; cursor: default; }

.d-track { display: flex; gap: .85rem; overflow-x: auto; padding: .25rem .25rem 1rem; margin: 0 -.25rem; list-style: none; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch; scroll-padding: .25rem; }
.d-track::-webkit-scrollbar { display: none; }
.d-track > li { flex: none; scroll-snap-align: start; width: 240px; }
@media (max-width: 520px) { .d-track > li { width: 74vw; max-width: 260px; } }

.d-card { display: flex; flex-direction: column; height: 100%; background: var(--d-card); border: 1px solid var(--d-line); border-radius: 16px; overflow: hidden; text-decoration: none; color: inherit; transition: transform .18s, box-shadow .18s, border-color .18s; }
.d-card:hover, .d-card:focus-visible { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(10,30,35,.12); border-color: #B2EBF2; outline: none; }
.d-card.is-lead { border-color: #FFD36A; box-shadow: 0 0 0 1px #FFD36A inset; }
.d-cover { position: relative; aspect-ratio: 4 / 3; background: #E6EEF0; overflow: hidden; }
.d-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.d-cover-empty { display: grid; place-items: center; color: #fff; font-size: 2.6rem; font-weight: 800; letter-spacing: .02em; }
.d-cover-empty.g0 { background: linear-gradient(135deg, #00BCD4, #0097A7); }
.d-cover-empty.g1 { background: linear-gradient(135deg, #5C6BC0, #3949AB); }
.d-cover-empty.g2 { background: linear-gradient(135deg, #EC407A, #AD1457); }
.d-cover-empty.g3 { background: linear-gradient(135deg, #26A69A, #00695C); }
.d-cover-empty.g4 { background: linear-gradient(135deg, #FFA726, #EF6C00); }
.d-cover-empty.g5 { background: linear-gradient(135deg, #7E57C2, #4527A0); }
.d-badges { position: absolute; top: 8px; left: 8px; right: 8px; display: flex; flex-direction: column; align-items: flex-start; gap: .25rem; }
.d-badge { font-size: .68rem; font-weight: 800; padding: .25rem .5rem; border-radius: 999px; background: rgba(26,26,46,.78); color: #fff; backdrop-filter: blur(4px); line-height: 1.1; display: inline-flex; align-items: center; gap: .25rem; max-width: 100%; }
.d-badge.lead { background: #FFC857; color: #3B2B00; }
.d-badge i { font-size: .62rem; }
.d-badge.new { background: #2E9E5B; }
.d-badge.off { background: rgba(209,67,67,.9); }
.d-body { padding: .7rem .85rem .85rem; display: flex; flex-direction: column; gap: .22rem; flex: 1; }
.d-name { font-weight: 800; font-size: 1rem; color: #1A1A2E; margin: 0; line-height: 1.25; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.d-sub { font-size: .8rem; color: var(--d-muted); margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.d-rating { font-size: .82rem; color: #1A1A2E; margin: 0; display: flex; align-items: center; gap: .3rem; }
.d-rating .star { color: #F5A524; }
.d-rating .muted { color: var(--d-muted); }
.d-meta { font-size: .76rem; color: var(--d-muted); margin: 0; }
.d-cta { margin-top: auto; padding-top: .55rem; font-size: .86rem; font-weight: 700; color: #00747F; display: flex; align-items: center; justify-content: space-between; }
.d-cta .off { color: var(--d-muted); font-weight: 600; }
.d-card:hover .d-cta i { transform: translateX(3px); }
.d-cta i { transition: transform .18s; }

/* Loading skeleton */
.d-skel .d-row-head h2 { width: 220px; height: 22px; border-radius: 6px; background: #E3EBED; }
.d-skel .d-card { pointer-events: none; }
.d-skel .d-cover { background: linear-gradient(90deg, #E6EEF0 25%, #F2F7F8 50%, #E6EEF0 75%); background-size: 200% 100%; animation: d-shimmer 1.2s infinite; }
.d-skel .d-name, .d-skel .d-sub { height: 14px; border-radius: 4px; background: #E6EEF0; }
.d-skel .d-sub { width: 60%; }
@keyframes d-shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .d-skel .d-cover { animation: none; } }

@media (max-width: 768px) {
  .discover-head { padding: 22px 1rem 36px; }
  .discover-tools { padding: 0 1rem; }
  .discover-tools-inner { margin-top: -16px; padding: .6rem .6rem .5rem; border-radius: 14px; }
  .d-filter-label { width: auto; min-width: 50px; font-size: .62rem; }
  .d-filter-row { gap: .5rem; }
  .discover-body { padding-left: 1rem; padding-right: 1rem; }
  .discover-search { padding-left: .9rem; }
  .discover-search-btn { display: none; }
  .discover-head h1 { margin-bottom: .5rem; }
  .discover-lead { font-size: 1.05rem; margin-bottom: 1.1rem; }
  .discover-actions { gap: .55rem; }
  .d-hero-btn { flex: 1 1 auto; min-height: 50px; padding: .7rem 1.1rem; font-size: .98rem; }
  .d-hero-btn.is-user span { max-width: 60vw; }
  .discover-eyebrow { font-size: .7rem; letter-spacing: .08em; }
  .d-row-head h2 { font-size: 1.08rem; }
}
