/* =========================================================
   40UP-NET — styles.css
   Mature adult classifieds. Mobile-first.
   All classes prefixed with `up-` for namespace isolation.
   ========================================================= */

/* ---------- Tokens ---------- */
:root {
  --up-header:         #1a1a2e;
  --up-header-hover:   #2a2a42;
  --up-accent:         #8b2252;
  --up-accent-hover:   #6e1a41;
  --up-accent-light:   rgba(139, 34, 82, 0.08);
  --up-online:         #22c55e;
  --up-recent:         #a78bfa;

  --up-bg:             #f0f0f5;
  --up-card:           #ffffff;
  --up-text:           #1a1a2e;
  --up-muted:          #6b6b80;
  --up-border:         #dddde5;
  --up-border-strong:  #c8c8d4;

  --up-radius:         8px;
  --up-radius-sm:      6px;

  --up-shadow-xs:  0 1px 2px rgba(26, 26, 46, 0.04);
  --up-shadow-sm:  0 2px 8px rgba(26, 26, 46, 0.06);
  --up-shadow-md:  0 6px 20px rgba(26, 26, 46, 0.10);

  --up-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
             Helvetica, Arial, sans-serif;

  --up-header-h: 56px;
  --up-max-w: 1160px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: var(--up-font);
  background: var(--up-bg);
  color: var(--up-text);
  line-height: 1.55;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; cursor: pointer; }

/* ---------- Container ---------- */
.up-container {
  width: 100%;
  max-width: var(--up-max-w);
  margin-inline: auto;
  padding-inline: 1rem;
}

/* ---------- Buttons ---------- */
.up-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.65rem 1.15rem;
  border: 2px solid transparent;
  border-radius: var(--up-radius-sm);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1;
  letter-spacing: 0.01em;
  transition: all 0.2s ease;
  white-space: nowrap;
}
.up-btn:active { transform: translateY(1px); }

.up-btn-accent {
  background: var(--up-accent);
  color: #fff;
  border-color: var(--up-accent);
}
.up-btn-accent:hover { background: var(--up-accent-hover); border-color: var(--up-accent-hover); }

.up-btn-outline {
  background: transparent;
  color: var(--up-header);
  border-color: var(--up-border-strong);
}
.up-btn-outline:hover { background: var(--up-header); color: #fff; border-color: var(--up-header); }

.up-btn-block { width: 100%; }

/* ---------- Header ---------- */
.up-header {
  background: var(--up-header);
  color: #fff;
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
  min-height: var(--up-header-h);
}

.up-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: var(--up-header-h);
}

.up-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: #fff;
}
.up-logo img {
  height: 30px;
  width: auto;
  display: block;
}
.up-logo-text {
  font-weight: 700;
  font-size: 1.125rem;
  letter-spacing: -0.01em;
}
.up-logo-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 0.4rem;
  padding: 0.15rem 0.4rem;
  background: var(--up-accent);
  color: #fff;
  border-radius: 4px;
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  line-height: 1;
}

/* Burger */
.up-burger {
  background: none;
  border: 0;
  padding: 0.5rem;
  width: 40px;
  height: 40px;
  display: grid;
  place-content: center;
  border-radius: 6px;
}
.up-burger:hover { background: rgba(255,255,255,0.08); }
.up-burger span {
  display: block;
  width: 20px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.2s ease;
}
.up-burger span + span { margin-top: 5px; }
.up-burger.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.up-burger.is-active span:nth-child(2) { opacity: 0; }
.up-burger.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Nav */
.up-nav {
  position: fixed;
  top: var(--up-header-h);
  left: 0;
  right: 0;
  background: var(--up-header);
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: 0.75rem 1rem 1.25rem;
  transform: translateY(-120%);
  transition: transform 0.3s ease;
  box-shadow: 0 12px 24px rgba(0,0,0,0.2);
  max-height: calc(100vh - var(--up-header-h));
  overflow-y: auto;
}
.up-nav.is-open { transform: translateY(0); }

.up-nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.up-nav a {
  display: block;
  color: #fff;
  text-decoration: none;
  padding: 0.8rem 1rem;
  border-radius: var(--up-radius-sm);
  font-weight: 500;
  font-size: 0.9375rem;
  transition: background 0.2s ease;
  letter-spacing: 0.01em;
}
.up-nav a:hover { background: var(--up-header-hover); }
.up-nav .up-btn-accent {
  margin-top: 0.5rem;
  text-align: center;
}
.up-nav .up-btn-accent:hover { background: var(--up-accent-hover); }

/* ---------- Breadcrumb ---------- */
.up-breadcrumb {
  padding: 0.9rem 0 0.25rem;
  font-size: 0.8125rem;
  color: var(--up-muted);
  letter-spacing: 0.01em;
}
.up-breadcrumb a {
  color: var(--up-header);
  text-decoration: none;
  font-weight: 600;
}
.up-breadcrumb a:hover { text-decoration: underline; }
.up-breadcrumb span { margin-inline: 0.35rem; }
.up-breadcrumb [aria-current="page"] { color: var(--up-muted); font-weight: 500; }

/* ---------- Page header ---------- */
.up-page-head {
  padding: 0.75rem 0 1.25rem;
}
.up-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--up-accent);
  margin-bottom: 0.5rem;
}
.up-eyebrow-badge {
  background: var(--up-accent);
  color: #fff;
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
  font-size: 0.6rem;
  font-weight: 800;
}
.up-page-head h1 {
  font-size: 1.625rem;
  line-height: 1.15;
  color: var(--up-header);
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
  font-weight: 700;
}
.up-page-head .up-tagline {
  color: var(--up-muted);
  font-size: 0.875rem;
  max-width: 70ch;
  line-height: 1.55;
}

/* ---------- Filter tabs ---------- */
.up-filters {
  margin-top: 1rem;
}
.up-filters-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.8rem;
  background: #fff;
  border: 1.5px solid var(--up-border-strong);
  border-radius: var(--up-radius-sm);
  font-weight: 600;
  font-size: 0.8125rem;
  color: var(--up-header);
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.up-filters-toggle:hover { border-color: var(--up-header); }
.up-filters-toggle svg { flex-shrink: 0; width: 16px; height: 16px; }
.up-filters-toggle[aria-expanded="true"] {
  background: var(--up-header);
  color: #fff;
  border-color: var(--up-header);
}

.up-tab-bar {
  display: none;
  gap: 0;
  margin-top: 0.6rem;
  border-bottom: 2px solid var(--up-border);
}
.up-tab-bar.is-open { display: flex; }

.up-tab {
  padding: 0.6rem 1rem;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  color: var(--up-muted);
  font-size: 0.8125rem;
  font-weight: 600;
  white-space: nowrap;
  transition: color 0.15s ease, border-color 0.15s ease;
  letter-spacing: 0.01em;
}
.up-tab:hover { color: var(--up-header); }
.up-tab.is-active {
  color: var(--up-accent);
  border-bottom-color: var(--up-accent);
}

/* ---------- Layout grid ---------- */
.up-layout {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-areas:
    "listings"
    "loadmore"
    "info"
    "sidebar";
  gap: 1.25rem;
  padding-bottom: 1.5rem;
}
.up-listings  { grid-area: listings; }
.up-load-more { grid-area: loadmore; }
.up-sidebar   { grid-area: sidebar; }
.up-info      { grid-area: info; }

/* ---------- Listing cards (horizontal) ---------- */
.up-listings {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

.up-card {
  display: flex;
  flex-direction: row;
  background: var(--up-card);
  border: 1px solid var(--up-border);
  border-radius: var(--up-radius);
  overflow: hidden;
  box-shadow: var(--up-shadow-xs);
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.up-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--up-shadow-md);
  border-color: var(--up-border-strong);
}
.up-card:focus-visible {
  outline: 3px solid var(--up-accent);
  outline-offset: 2px;
}

.up-card-img {
  position: relative;
  width: 120px;
  aspect-ratio: auto;
  min-height: 160px;
  overflow: hidden;
  background: linear-gradient(135deg, #8b2252, #1a1a2e);
  flex-shrink: 0;
}
/* Varied gradient placeholders */
.up-card:nth-child(6n+1) .up-card-img { background: linear-gradient(135deg, #8b2252, #1a1a2e); }
.up-card:nth-child(6n+2) .up-card-img { background: linear-gradient(135deg, #1a1a2e, #8b2252); }
.up-card:nth-child(6n+3) .up-card-img { background: linear-gradient(135deg, #4a1942, #1a1a2e); }
.up-card:nth-child(6n+4) .up-card-img { background: linear-gradient(135deg, #2e1a3e, #8b2252); }
.up-card:nth-child(6n+5) .up-card-img { background: linear-gradient(135deg, #8b2252, #4a1942); }
.up-card:nth-child(6n)   .up-card-img { background: linear-gradient(135deg, #1a1a2e, #4a1942); }

.up-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.up-badge {
  position: absolute;
  top: 0.6rem;
  left: 0.6rem;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: rgba(26, 26, 46, 0.85);
  backdrop-filter: blur(6px);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.3rem 0.55rem;
  border-radius: 999px;
  letter-spacing: 0.01em;
}
.up-badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #9ca3af;
}
.up-badge.online .up-badge-dot {
  background: var(--up-online);
  animation: upPulse 2s infinite;
}
.up-badge.recent .up-badge-dot {
  background: var(--up-recent);
}
@keyframes upPulse {
  0%   { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7); }
  70%  { box-shadow: 0 0 0 6px rgba(34, 197, 94, 0); }
  100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

.up-card-time {
  position: absolute;
  bottom: 0.6rem;
  right: 0.6rem;
  background: rgba(26, 26, 46, 0.7);
  backdrop-filter: blur(6px);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 500;
  padding: 0.25rem 0.5rem;
  border-radius: 999px;
}

.up-card-body {
  padding: 0.9rem 1rem 1rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.up-card-title {
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--up-header);
  margin-bottom: 0.4rem;
  letter-spacing: -0.005em;
}

.up-card-desc {
  color: var(--up-muted);
  font-size: 0.8125rem;
  line-height: 1.5;
  margin-bottom: 0.75rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.up-card-labels {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: auto;
  margin-bottom: 0.75rem;
}
.up-label {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--up-accent);
  border-bottom: 1.5px solid var(--up-accent);
  padding-bottom: 0.1rem;
}
.up-label-loc {
  color: var(--up-muted);
  border-color: var(--up-border-strong);
}

.up-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: auto;
}

.up-view-btn {
  display: inline-block;
  background: var(--up-accent);
  color: #fff;
  padding: 0.55rem 1.1rem;
  border-radius: var(--up-radius-sm);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: background 0.2s ease;
}
.up-view-btn::after { content: " \2192"; }
.up-card:hover .up-view-btn { background: var(--up-header); }

.up-card-user {
  display: block;
  font-size: 0.8125rem;
  color: var(--up-muted);
  font-weight: 600;
  margin-bottom: 0.55rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ---------- Sidebar ---------- */
.up-sidebar {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

.up-widget {
  background: var(--up-card);
  border: 1px solid var(--up-border);
  border-left: 3px solid var(--up-accent);
  border-radius: var(--up-radius);
  padding: 1.1rem 1rem;
  box-shadow: var(--up-shadow-xs);
}

.up-widget-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--up-header);
  margin-bottom: 0.75rem;
}

.up-city-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}
.up-city-list a {
  display: block;
  padding: 0.5rem 0.6rem;
  border-radius: var(--up-radius-sm);
  color: var(--up-text);
  text-decoration: none;
  font-size: 0.8125rem;
  font-weight: 500;
  transition: background 0.15s ease, color 0.15s ease, padding 0.15s ease;
}
.up-city-list a:hover {
  background: var(--up-bg);
  color: var(--up-accent);
  padding-left: 0.85rem;
}

.up-widget-cta {
  background: var(--up-header);
  color: #fff;
  border-color: var(--up-header);
  border-left-color: var(--up-accent);
  text-align: center;
}
.up-widget-cta .up-widget-title { color: #fff; }
.up-widget-cta p {
  font-size: 0.8125rem;
  color: rgba(255,255,255,0.7);
  margin-bottom: 0.85rem;
  line-height: 1.5;
}

/* ---------- Load more ---------- */
.up-load-more {
  text-align: center;
  padding: 0.5rem 0;
}

/* ---------- Info section ---------- */
.up-info {
  background: #fff;
  border: 1px solid var(--up-border);
  border-radius: var(--up-radius);
  padding: 1.25rem 1.1rem;
  box-shadow: var(--up-shadow-xs);
}
.up-info h2 {
  font-size: 1.25rem;
  color: var(--up-header);
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}
.up-info-lead {
  color: var(--up-muted);
  font-size: 0.875rem;
  margin-bottom: 1.1rem;
  line-height: 1.65;
}
.up-info-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  margin-bottom: 1.1rem;
}
.up-info-card {
  background: var(--up-bg);
  border-radius: var(--up-radius-sm);
  padding: 1rem;
  border: 1px solid var(--up-border);
}
.up-info-card h3 {
  font-size: 0.875rem;
  color: var(--up-header);
  margin-bottom: 0.6rem;
  font-weight: 700;
}
.up-info-card ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.up-info-card li {
  font-size: 0.8125rem;
  color: var(--up-muted);
  padding-left: 1rem;
  position: relative;
  line-height: 1.45;
}
.up-info-card li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5rem;
  width: 5px;
  height: 5px;
  background: var(--up-accent);
  border-radius: 50%;
}

.up-areas {
  margin-bottom: 1.1rem;
}
.up-areas h3 {
  font-size: 0.875rem;
  color: var(--up-header);
  margin-bottom: 0.65rem;
  font-weight: 700;
}
.up-area-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.up-area-tag {
  display: inline-block;
  padding: 0.35rem 0.7rem;
  background: var(--up-bg);
  border: 1px solid var(--up-border);
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--up-text);
}

.up-safety {
  background: #fef3c7;
  border-left: 3px solid #f59e0b;
  padding: 0.85rem 1rem;
  border-radius: var(--up-radius-sm);
  font-size: 0.8125rem;
  color: #78350f;
  line-height: 1.55;
}
.up-safety strong { color: #78350f; }

/* ---------- Footer ---------- */
.up-footer {
  background: var(--up-header);
  color: #a0a0b8;
  padding: 2rem 0 1.25rem;
  margin-top: auto;
}

.up-footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1.5rem 1rem;
  margin-bottom: 1.75rem;
}

.up-footer-brand { grid-column: 1 / -1; }
.up-footer-logo {
  display: flex;
  align-items: center;
  margin-bottom: 0.6rem;
}
.up-footer-logo img { height: 28px; width: auto; display: block; }
.up-footer-logo-text {
  font-weight: 700;
  font-size: 1rem;
  color: #fff;
}
.up-footer-logo-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 0.35rem;
  padding: 0.1rem 0.35rem;
  background: var(--up-accent);
  color: #fff;
  border-radius: 3px;
  font-size: 0.55rem;
  font-weight: 800;
  letter-spacing: 0.05em;
}

.up-footer-col p {
  font-size: 0.8125rem;
  line-height: 1.6;
  color: #8585a0;
}
.up-footer-heading {
  color: #fff;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
  font-weight: 700;
}
.up-footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.up-footer-col a {
  color: #8585a0;
  text-decoration: none;
  font-size: 0.8125rem;
  transition: color 0.2s ease;
}
.up-footer-col a:hover { color: #fff; }

.up-footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 1.1rem;
  text-align: center;
  font-size: 0.75rem;
  color: #8585a0;
}
.up-footer-bottom p + p { margin-top: 0.4rem; }
.up-footer-disclaimer {
  font-size: 0.65rem;
  line-height: 1.5;
  color: #6b6b80;
  max-width: 70ch;
  margin-inline: auto;
}

/* =========================================================
   Breakpoints
   ========================================================= */

/* >= 560px */
@media (min-width: 560px) {
  .up-card-img {
    width: 180px;
    min-height: 220px;
  }
  .up-card-body {
    padding: 1rem 1.1rem;
  }
  .up-card-desc {
    -webkit-line-clamp: 3;
  }
  .up-info-grid { grid-template-columns: repeat(2, 1fr); }
}

/* >= 720px */
@media (min-width: 720px) {
  .up-container { padding-inline: 1.5rem; }
  .up-page-head h1 { font-size: 2rem; }
  .up-card-img { width: 220px; }
  .up-card-title { font-size: 1.0625rem; }
  .up-info { padding: 1.75rem 1.5rem; }
  .up-info h2 { font-size: 1.5rem; }
  .up-footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; gap: 2rem; }
  .up-footer-brand { grid-column: auto; }
  .up-breadcrumb { padding: 1.1rem 0 0.35rem; }

  .up-filters-toggle { display: none; }
  .up-tab-bar {
    display: flex;
    margin-top: 0;
  }
}

/* >= 980px */
@media (min-width: 980px) {
  .up-burger { display: none; }

  .up-nav {
    position: static;
    transform: none;
    background: none;
    border: 0;
    box-shadow: none;
    padding: 0;
    max-height: none;
    overflow: visible;
  }
  .up-nav ul {
    flex-direction: row;
    align-items: center;
    gap: 0.2rem;
  }
  .up-nav a {
    padding: 0.5rem 0.85rem;
    font-size: 0.875rem;
  }
  .up-nav a:hover { background: rgba(255,255,255,0.08); }
  .up-nav .up-btn-accent {
    margin-top: 0;
    margin-left: 0.4rem;
    padding: 0.6rem 1.1rem;
  }
  .up-nav .up-btn-accent:hover { background: var(--up-accent-hover); }

  .up-layout {
    grid-template-columns: minmax(0, 1fr) 280px;
    grid-template-areas:
      "listings sidebar"
      "loadmore sidebar"
      "info     sidebar";
    gap: 1.25rem 1.75rem;
    align-items: start;
    padding-bottom: 2rem;
  }

  .up-sidebar {
    position: sticky;
    top: calc(var(--up-header-h) + 1rem);
    align-self: start;
  }

  .up-page-head h1 { font-size: 2.25rem; }
  .up-page-head { padding: 1rem 0 1.5rem; }
  .up-card-img { width: 240px; }
  .up-card-title { font-size: 1.125rem; }
  .up-info-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}
