/* Roomdrop — light pink / white, shared styles */

:root {
  --bg: #fff8fb;
  --bg-section: #ffffff;
  --bg-pink: #fce4ec;
  --accent: #f06292;
  --accent-dark: #c2185b;
  --text: #4a3728;
  --text-muted: #8d6b7a;
  --navy: #1e293b;
  --border: rgba(240, 98, 146, 0.2);
  --radius: 20px;
  --radius-sm: 14px;
  --pill: 999px;
  --shadow: 0 8px 32px rgba(240, 98, 146, 0.12);
  --shadow-sm: 0 2px 12px rgba(0, 0, 0, 0.06);
  --font: "DM Sans", system-ui, sans-serif;
  --font-accent: "Lora", Georgia, serif;
  --max: 1120px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  background-image: radial-gradient(ellipse 100% 50% at 100% 0%, rgba(252, 228, 236, 0.5) 0%, transparent 50%);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent-dark);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.site-header--transparent {
  position: absolute;
  left: 0;
  right: 0;
  background: rgba(255, 250, 252, 0.85);
  border-bottom-color: rgba(248, 187, 208, 0.4);
}

/* Guide page: match storybook-era pink header + logo ring */
.site-header--guide-brand {
  background: rgba(255, 250, 252, 0.96);
  border-bottom-color: rgba(248, 187, 208, 0.45);
}

.guide-site .logo__mark {
  border-width: 2px;
  box-shadow: 0 2px 10px rgba(240, 98, 146, 0.22);
  outline: 2px solid rgba(240, 98, 146, 0.28);
  outline-offset: 0;
}

.guide-site .logo:hover .logo__mark {
  outline-color: rgba(240, 98, 146, 0.45);
  box-shadow: 0 3px 14px rgba(240, 98, 146, 0.32);
}

.site-header__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.85rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  color: var(--navy);
  text-decoration: none;
}

.logo:hover {
  color: var(--accent-dark);
  text-decoration: none;
}

.logo__mark {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: contain;
  display: block;
  flex-shrink: 0;
  background: #fff;
  padding: 2px;
  box-sizing: border-box;
  border: 2px solid var(--accent);
  box-shadow: 0 2px 8px rgba(240, 98, 146, 0.28);
}

.logo:hover .logo__mark {
  border-color: var(--accent-dark);
  box-shadow: 0 3px 12px rgba(240, 98, 146, 0.38);
}

.nav-main {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.nav-main a {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-muted);
  text-decoration: none;
}

.nav-main a:hover,
.nav-main a[aria-current="page"] {
  color: var(--accent-dark);
  box-shadow: 0 2px 0 0 var(--accent);
}

.header-actions {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.header-actions__user {
  display: inline-flex;
  align-items: center;
  line-height: 0;
}

.header-actions__avatar {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--bg-pink);
  border: 2px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.55rem 1.15rem;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--pill);
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s;
}

.btn:hover {
  text-decoration: none;
}

.btn--primary {
  background: linear-gradient(135deg, #ff8fab, var(--accent));
  color: #fff;
  box-shadow: 0 4px 16px rgba(240, 98, 146, 0.35);
}

.btn--outline {
  background: #fff;
  color: var(--text);
  border-color: var(--border);
}

.btn--outline:hover {
  border-color: var(--accent);
  color: var(--accent-dark);
}

.btn--ghost {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.85);
  color: #fff;
}

.btn--lg {
  padding: 0.75rem 1.4rem;
  font-size: 1rem;
}

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

.btn--muted {
  background: #f5f5f5;
  color: var(--text);
  border-color: #e0e0e0;
}

/* ---------- Hero (landing) ---------- */
.hero-page {
  position: relative;
}

.hero {
  position: relative;
  min-height: min(78vh, 720px);
  display: flex;
  align-items: flex-end;
}

.hero__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(255, 250, 252, 0.2) 0%,
    rgba(252, 228, 236, 0.55) 50%,
    rgba(255, 248, 252, 0.95) 100%
  );
}

.hero__inner {
  position: relative;
  z-index: 2;
  max-width: var(--max);
  margin: 0 auto;
  padding: 5.5rem 1.25rem 3rem;
  width: 100%;
}

.hero__inner--split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
}

.hero__content {
  text-align: center;
  max-width: 36rem;
  margin: 0 auto;
}

.hero__inner--split .hero__content {
  text-align: left;
  margin: 0;
}

.hero__kicker {
  font-size: 0.95rem;
  font-weight: 600;
  color: #5d4037;
  margin-bottom: 0.35rem;
}

.hero__title {
  margin: 0 0 0.75rem;
  font-size: clamp(1.65rem, 4vw, 2.35rem);
  font-weight: 800;
  color: #6d1f3a;
  letter-spacing: -0.02em;
}

.hero__title .accent {
  font-family: var(--font-accent);
  font-style: italic;
  font-weight: 500;
  color: var(--accent-dark);
}

.hero__lead {
  margin: 0 0 1.25rem;
  color: var(--text-muted);
  font-size: 1.05rem;
}

.hero-cta-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  max-width: 520px;
  margin: 0 auto 1.5rem;
}

.hero-cta-bar input {
  flex: 1;
  min-width: 120px;
  padding: 0.65rem 1rem;
  border-radius: var(--pill);
  border: 1px solid var(--border);
  font: inherit;
}

.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.hero__inner--split .hero-cta-row {
  justify-content: flex-start;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  justify-content: center;
  font-size: 0.95rem;
  font-weight: 700;
  color: #8e2152;
}

.trust-row span {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0;
  background: transparent;
  border: none;
}

.hero-svg-wrap {
  justify-self: end;
  max-width: 380px;
}

@media (max-width: 900px) {
  .hero__inner--split {
    grid-template-columns: 1fr;
  }

  .hero__inner--split .hero__content {
    text-align: center;
    margin: 0 auto;
  }

  .hero-svg-wrap {
    justify-self: center;
    order: -1;
  }

  .nav-main {
    display: none;
  }
}

/* ---------- Sections ---------- */
.section {
  padding: 3rem 1.25rem;
}

.section--tint {
  background: linear-gradient(180deg, #fff 0%, #fff5f9 100%);
}

.section__head {
  max-width: var(--max);
  margin: 0 auto 1.75rem;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
}

.section__head--bar {
  background: #fff;
  padding: 1rem 1.35rem;
  border-radius: 18px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.section__eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.section__title {
  margin: 0;
  font-size: 1.55rem;
  font-weight: 800;
  color: var(--navy);
}

.link-more {
  font-weight: 700;
  color: var(--accent-dark);
}

.grid-3 {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
}

/* Listing pricing (demo checkout before list-property form) */
.plan-grid {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
  align-items: stretch;
}

.plan-card {
  position: relative;
  background: #fff;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  padding: 1.75rem 1.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.plan-card--featured {
  border-color: rgba(240, 98, 146, 0.55);
  box-shadow: var(--shadow);
}

.plan-card__badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  margin: 0;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  background: var(--accent);
  padding: 0.3rem 0.65rem;
  border-radius: var(--pill);
}

.plan-card__name {
  margin: 0 0 0.5rem;
  font-size: 1.15rem;
  font-weight: 800;
  color: #6d1f3a;
}

.plan-card__price {
  margin: 0 0 0.35rem;
  line-height: 1.2;
}

.plan-card__amount {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--accent-dark);
}

.plan-card__unit {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-muted);
}

.plan-card__tagline {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.plan-card__features {
  margin: 0 0 1.25rem;
  padding: 0 0 0 1.15rem;
  font-size: 0.9rem;
  color: var(--text);
  line-height: 1.55;
  flex: 1;
}

.plan-card__features li {
  margin-bottom: 0.4rem;
}

.plan-card__cta {
  margin-top: auto;
}

.plan-demo-note {
  max-width: var(--max);
  margin: 1.75rem auto 0;
  padding: 0 1.25rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

@media (max-width: 900px) {
  .plan-grid {
    grid-template-columns: 1fr;
    max-width: 420px;
  }
}

.grid-4 {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem;
}

.grid-apt {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.25rem;
}

@media (max-width: 1100px) {
  .grid-apt {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .grid-apt {
    grid-template-columns: 1fr;
  }
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

/* ---------- Cards ---------- */
.card {
  background: #fff;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.card__media {
  aspect-ratio: 4/3;
  object-fit: cover;
  width: 100%;
}

.card__body {
  padding: 1.1rem 1.2rem 1.25rem;
}

.card__title {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--navy);
}

.card__meta {
  margin: 0;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.card__price {
  font-weight: 800;
  color: var(--accent-dark);
  margin: 0.5rem 0;
}

.card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.tag {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.25rem 0.55rem;
  border-radius: var(--pill);
  background: var(--bg-pink);
  color: var(--accent-dark);
}

.tag--neutral {
  background: #f3f0f4;
  color: var(--text-muted);
}

.card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: #fff;
  cursor: pointer;
  color: var(--accent);
}

.roommate-card {
  text-align: center;
  padding: 1.25rem 1rem;
}

.roommate-card .avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  margin: 0 auto 0.75rem;
  object-fit: cover;
  border: 3px solid #fff;
  outline: 3px solid rgba(240, 98, 146, 0.3);
}

.resource-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 1.35rem;
  background: linear-gradient(135deg, #fce4ec, #e3f2fd);
  margin-bottom: 0.65rem;
}

.section__intro {
  max-width: var(--max);
  margin: -0.5rem auto 1.5rem;
  color: var(--text-muted);
}

.section__intro--tight {
  max-width: 34rem;
  font-size: 0.98rem;
  line-height: 1.5;
}

/* Helpful resources: image cards, short copy */
.resource-grid {
  gap: 1.35rem;
}

.resource-grid .card__media {
  aspect-ratio: 3 / 2;
  object-position: center;
}

.resource-grid .card__body {
  padding-top: 1rem;
}

.resource-grid .card__meta {
  line-height: 1.45;
}

.resource-grid .link-more {
  margin-top: 0.5rem;
  display: inline-block;
}

/* ---------- Search (apartments page) ---------- */
.search-toolbar {
  max-width: var(--max);
  margin: 0 auto 1.5rem;
  display: flex;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.search-toolbar input[type="search"] {
  flex: 1;
  min-width: 200px;
  padding: 0.75rem 1.1rem;
  border-radius: var(--pill);
  border: 1px solid var(--border);
  font: inherit;
  background: #fff;
}

.search-toolbar__filter {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  border: none;
  background: linear-gradient(135deg, #ff8fab, var(--accent));
  color: #fff;
  cursor: pointer;
  font-size: 1.15rem;
  line-height: 1;
  flex-shrink: 0;
  box-shadow: 0 4px 14px rgba(240, 98, 146, 0.35);
}

.search-toolbar__filter:hover {
  filter: brightness(1.05);
}

/* ---------- Detail page ---------- */
.detail-hero {
  position: relative;
  min-height: 320px;
}

.detail-hero__price {
  position: absolute;
  bottom: 1rem;
  right: 1.25rem;
  z-index: 3;
  background: var(--accent);
  color: #fff;
  padding: 0.55rem 1.1rem;
  border-radius: var(--radius-sm);
  font-weight: 800;
  box-shadow: var(--shadow);
}

/* Location line: theme rose, readable on light hero gradient */
.detail-hero .detail-hero__location {
  margin: 0.35rem 0 0;
  color: var(--accent-dark);
  font-weight: 700;
  text-shadow:
    0 0 14px rgba(255, 255, 255, 0.95),
    0 1px 0 rgba(255, 255, 255, 0.6),
    0 2px 10px rgba(194, 24, 91, 0.25);
}

.gallery {
  max-width: var(--max);
  margin: 0 auto;
  padding: 2rem 1.25rem;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 0.75rem;
}

.gallery__main {
  border-radius: var(--radius);
  overflow: hidden;
}

.gallery__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
}

.gallery__grid img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

/* Third gallery image (2×2 grid, top-right): bias crop toward building/ground, less empty sky */
.gallery__grid img:nth-child(2) {
  object-position: 50% 78%;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1rem;
  align-items: stretch;
}

.detail-feature-card {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.detail-section {
  max-width: var(--max);
  margin: 0 auto;
  padding: 3rem 1.25rem;
}

.detail-section__title {
  margin: 0 0 1rem;
}

.detail-layout {
  display: grid;
  grid-template-columns:
    minmax(0, 0.6fr) minmax(0, 0.6fr) minmax(0, 0.475fr) minmax(0, 0.475fr)
    minmax(0, 1fr);
  grid-template-rows: repeat(3, auto);
  gap: 1rem;
  align-items: stretch;
}

.detail-features,
.detail-middle {
  display: contents;
}

.detail-features .feature-grid,
.detail-middle-features {
  display: contents;
}

.detail-features .feature-grid > :nth-child(1) {
  grid-column: 1;
  grid-row: 1;
}

.detail-features .feature-grid > :nth-child(2) {
  grid-column: 2;
  grid-row: 1;
}

.detail-features .feature-grid > :nth-child(3) {
  grid-column: 1;
  grid-row: 2;
}

.detail-features .feature-grid > :nth-child(4) {
  grid-column: 2;
  grid-row: 2;
}

.detail-features .feature-grid > :nth-child(5) {
  grid-column: 1;
  grid-row: 3;
}

.detail-features .feature-grid > :nth-child(6) {
  grid-column: 2;
  grid-row: 3;
}

.detail-middle-features > :nth-child(1) {
  grid-column: 3;
  grid-row: 1;
}

.detail-middle-features > :nth-child(2) {
  grid-column: 4;
  grid-row: 1;
}

.detail-layout > .detail-map-card {
  grid-column: 5;
  grid-row: 1 / -1;
  min-height: 0;
  align-self: stretch;
}

.detail-middle-features {
  grid-template-columns: 1fr 1fr;
}

.detail-landlord-card {
  grid-column: 3 / 5;
  grid-row: 2 / 4;
  height: 100%;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 1.25rem 1.35rem 1.35rem;
}

.detail-landlord-card__title {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--navy);
}

.detail-landlord-card__body {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.detail-landlord-row {
  display: flex;
  gap: 0.85rem;
  align-items: center;
}

.detail-landlord-avatar {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--bg-pink);
}

.detail-landlord-name {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.3;
  color: var(--navy);
}

.detail-landlord-email {
  margin: 0.2rem 0 0;
  font-size: 0.9rem;
  line-height: 1.35;
  color: var(--text-muted);
}

.detail-landlord-phone {
  margin: 1rem 0 0;
  font-size: 0.95rem;
  line-height: 1.4;
  color: var(--text);
}

.detail-landlord-cta {
  margin-top: auto;
  padding-top: 1.25rem;
}

.detail-side-card.detail-map-card {
  padding: 1rem 1.15rem 1.1rem;
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
}

.detail-column-head {
  margin-bottom: 0.5rem;
  flex-shrink: 0;
}

.detail-side-card__title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--navy);
}

.detail-side-card__meta {
  margin: 0.2rem 0 0;
  font-size: 0.78rem;
  line-height: 1.3;
  color: var(--text-muted);
}

.detail-map-stack {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.detail-map-frame {
  flex: 1 1 0;
  min-height: 88px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.06);
  background: #f6f2f7;
}

.detail-map-frame iframe {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
}

@media (max-width: 1024px) {
  .detail-layout {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
  }

  .detail-features,
  .detail-middle {
    display: block;
  }

  .detail-features .feature-grid,
  .detail-middle-features {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1rem;
  }

  .detail-features .feature-grid > *,
  .detail-middle-features > *,
  .detail-landlord-card {
    grid-column: auto;
    grid-row: auto;
  }

  .detail-features {
    grid-column: 1 / -1;
  }

  .detail-middle {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    grid-column: 1;
  }

  .detail-landlord-card {
    height: auto;
    justify-content: flex-start;
  }

  .detail-layout > .detail-map-card {
    grid-column: 2;
    grid-row: 2;
  }
}

@media (max-width: 768px) {
  .gallery {
    grid-template-columns: 1fr;
  }

  .detail-layout {
    grid-template-columns: 1fr;
  }

  .detail-features {
    grid-column: auto;
  }

  .detail-middle {
    grid-column: auto;
  }

  .detail-layout > .detail-map-card {
    grid-column: auto;
    grid-row: auto;
  }
}

/* ---------- Forms ---------- */
.form-shell {
  max-width: 720px;
  margin: -2.5rem auto 0;
  position: relative;
  z-index: 5;
  padding: 0 1.25rem 3rem;
}

.form-shell--wide {
  max-width: 900px;
}

.form-card {
  background: #fff;
  border-radius: calc(var(--radius) + 4px);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 2rem 1.75rem;
}

.form-section-title {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--navy);
}

.form-grid {
  display: grid;
  gap: 1rem;
}

.form-grid--2 {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.form-grid--3 {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

label.field,
.field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
}

.field input,
.field select,
.field textarea {
  padding: 0.65rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  font: inherit;
  background: #fffafc;
}

.field input:focus,
.field select:focus {
  outline: 2px solid var(--bg-pink);
  border-color: var(--accent);
}

.switch {
  width: 48px;
  height: 26px;
  border-radius: var(--pill);
  background: #e0e0e0;
  border: none;
  cursor: pointer;
  position: relative;
}

.switch[aria-checked="true"] {
  background: var(--accent);
}

.switch::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  background: #fff;
  border-radius: 50%;
  top: 2px;
  left: 2px;
  transition: transform 0.2s;
}

.switch[aria-checked="true"]::after {
  transform: translateX(22px);
}

.upload-circle {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  border: 2px dashed var(--border);
  display: grid;
  place-items: center;
  font-size: 0.8rem;
  color: var(--text-muted);
  cursor: pointer;
  background: #fffafc;
  text-align: center;
  line-height: 1.35;
  transition: border-color 0.15s, background 0.15s;
}

.upload-circle:hover {
  border-color: var(--accent);
  background: var(--bg-pink);
}

.property-photos__hint {
  margin: 0 0 0.85rem;
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.property-photos {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: flex-start;
}

.property-photos__upload {
  flex-shrink: 0;
  margin: 0;
}

.property-photos__upload-text {
  pointer-events: none;
  padding: 0 0.35rem;
}

.property-photos__preview-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  flex: 1;
  min-width: 0;
}

.property-photos__thumb {
  position: relative;
  width: 88px;
  height: 88px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.property-photos__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.property-photos__remove {
  position: absolute;
  top: 0.2rem;
  right: 0.2rem;
  width: 1.5rem;
  height: 1.5rem;
  border: none;
  border-radius: 50%;
  background: rgba(30, 41, 59, 0.75);
  color: #fff;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  padding: 0;
}

.property-photos__remove:hover {
  background: var(--accent-dark);
}

.segmented {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.segmented label {
  cursor: pointer;
}

.segmented input {
  position: absolute;
  opacity: 0;
}

.segmented span {
  display: inline-block;
  padding: 0.45rem 0.75rem;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border);
  font-size: 0.85rem;
  background: #fff;
}

.segmented input:checked + span {
  background: var(--bg-pink);
  border-color: var(--accent);
  color: var(--accent-dark);
  font-weight: 700;
}

.check-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.check-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  cursor: pointer;
}

.check-pill input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.check-pill span {
  padding: 0.35rem 0.65rem;
  border-radius: var(--pill);
  border: 2px solid var(--border);
  font-size: 0.85rem;
}

.check-pill input:checked + span {
  background: var(--bg-pink);
  border-color: var(--accent);
  color: var(--accent-dark);
  font-weight: 700;
}

/* Match page */
.match-hero {
  position: relative;
  min-height: 260px;
}

.match-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 252, 253, 0.15) 0%, rgba(252, 228, 236, 0.6) 100%);
}

.match-hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 4rem 1.25rem 2rem;
  max-width: 36rem;
  margin: 0 auto;
}

/* Subtitle: calm gray, still readable on bright photo */
.match-hero .match-hero__lead {
  margin: 0.75rem auto 0;
  max-width: 34rem;
  font-family: var(--font);
  font-style: normal;
  font-weight: 500;
  font-size: 1.05rem;
  line-height: 1.6;
  color: #4f4a52;
  text-shadow:
    0 0 12px rgba(255, 255, 255, 0.88),
    0 1px 2px rgba(255, 255, 255, 0.65);
}

.match-card {
  max-width: 900px;
  margin: -2rem auto 0;
  position: relative;
  z-index: 3;
}

.matching-layout {
  display: block;
}

.matching-layout.has-results {
  display: block;
}

.match-results-panel {
  padding: 0;
}

.match-mini-card {
  border: 1px solid rgba(240, 98, 146, 0.16);
  border-radius: var(--radius-sm);
  padding: 0.85rem;
  background: linear-gradient(180deg, #fff 0%, #fff8fb 100%);
  margin-bottom: 0.9rem;
}

.match-mini-card:last-child {
  margin-bottom: 0;
}

.match-long-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.match-long-grid .match-mini-card {
  margin-bottom: 0;
}

.match-mini-card__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}

.match-mini-card__person {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.match-mini-card__name {
  margin: 0;
  font-weight: 800;
  color: var(--navy);
}

.match-mini-card__score {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--accent-dark);
}

.match-mini-card .card__tags {
  margin-top: 0.7rem;
}

.match-mini-card__bar {
  margin-top: 0.75rem;
  height: 6px;
  border-radius: var(--pill);
  background: #f1ebf0;
  overflow: hidden;
}

.match-mini-card__bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #ff8fab 0%, #f06292 100%);
}

.is-hidden {
  display: none !important;
}

.matching-layout.has-results .match-results-panel {
  max-width: var(--max);
  margin: 0 auto;
}

.match-flow-shell {
  margin-top: 0;
  padding-top: 2rem;
}

.roommate-browse-direct {
  max-width: var(--max);
}

.roommate-browse-direct__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  max-width: none;
  margin: 0;
}

.roommate-browse-direct__grid .match-mini-card {
  margin-bottom: 0;
  padding: 0.8rem;
}

.roommate-browse-direct__grid .match-mini-card__head {
  justify-content: flex-start;
}

.roommate-browse-direct__grid .match-mini-card__person .avatar {
  width: 44px;
  height: 44px;
}

.roommate-browse-direct__grid .match-mini-card__name {
  font-size: 0.95rem;
}

.roommate-browse-direct__grid .card__meta {
  font-size: 0.78rem;
  line-height: 1.35;
}

.roommate-browse-direct__grid .card__tags {
  margin-top: 0.6rem;
}

.roommate-browse-direct__grid .roommate-card__email {
  margin-top: 0.5rem;
  font-size: 0.72rem;
  word-break: break-all;
}

@media (max-width: 1100px) {
  .roommate-browse-direct__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .roommate-browse-direct__grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .match-long-grid {
    grid-template-columns: 1fr;
  }
}

/* Auth */
.auth-split {
  min-height: min(88vh, 920px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  align-items: center;
  max-width: var(--max);
  margin: 0 auto;
  padding: 2.5rem 1.25rem 3rem;
}

.auth-split__intro .page-title {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

@media (max-width: 900px) {
  .auth-split {
    grid-template-columns: 1fr;
  }

  .auth-split__intro {
    text-align: center;
  }
}

.auth-wrap {
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.25rem;
  background: linear-gradient(180deg, #fce4ec 0%, var(--bg) 50%);
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: #fff;
  border-radius: 24px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.auth-tabs a {
  padding: 0.9rem;
  text-align: center;
  font-weight: 800;
  color: var(--text-muted);
  border-bottom: 3px solid #eee;
  text-decoration: none;
}

.auth-tabs a[aria-current="page"] {
  color: var(--accent-dark);
  border-bottom-color: var(--accent);
}

.auth-body {
  padding: 1.5rem;
}

.auth-error {
  margin: 0 0 1rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius, 12px);
  background: #f8d7da;
  color: #842029;
  font-size: 0.9rem;
}

.divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1rem 0;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* Match results */
.match-featured {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1.5rem;
  align-items: center;
  padding: 1.5rem;
  background: linear-gradient(135deg, #fff, #fff5f9);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 1.5rem;
}

.match-score {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  border: 4px solid var(--bg-pink);
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--accent-dark);
}

@media (max-width: 640px) {
  .match-featured {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .match-score {
    margin: 0 auto;
  }
}

/* Footer */
.site-footer {
  background: linear-gradient(180deg, #4a3540 0%, #3e2c35 100%);
  color: #e8e0e3;
  padding: 2.5rem 1.25rem 2rem;
  font-size: 0.9rem;
}

.site-footer a {
  color: #fff;
}

.site-footer__inner {
  max-width: var(--max);
  margin: 0 auto;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.25rem;
  margin-bottom: 1rem;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  align-items: center;
}

.social {
  display: flex;
  gap: 0.5rem;
}

.social a {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.1);
  text-decoration: none;
}

.page-hero {
  position: relative;
  min-height: 240px;
}

.page-hero .hero__overlay {
  background: linear-gradient(180deg, rgba(252, 228, 236, 0.5) 0%, rgba(255, 248, 252, 1) 100%);
}

.page-hero .hero__inner {
  padding-top: 4.5rem;
  padding-bottom: 2rem;
}

.page-title {
  margin: 0;
  font-size: 1.75rem;
  font-weight: 800;
  color: #6d1f3a;
}

.page-lead {
  margin: 0.35rem 0 0;
  color: var(--text-muted);
}

/* Website guide — mockup layout (guide.html) */
.guide-site {
  background: var(--bg);
  background-image: radial-gradient(ellipse 100% 50% at 100% 0%, rgba(252, 228, 236, 0.5) 0%, transparent 50%);
}

.guide-page {
  padding: 0 0 3rem;
  background: linear-gradient(180deg, transparent 0%, rgba(255, 245, 249, 0.65) 100%);
}

.guide-hero {
  text-align: center;
  padding: 2.25rem 1.25rem 2rem;
  max-width: 40rem;
  margin: 0 auto;
}

.guide-hero__title {
  margin: 0 0 1.25rem;
  font-size: clamp(1.35rem, 3.5vw, 1.85rem);
  font-weight: 800;
  color: var(--navy);
  line-height: 1.2;
}

.guide-hero__mascot {
  width: 120px;
  height: 120px;
  margin: 0 auto;
  object-fit: contain;
  border-radius: 50%;
  background: #fff;
  padding: 6px;
  box-sizing: border-box;
  border: 4px solid #fff;
  outline: 3px solid rgba(240, 98, 146, 0.35);
  box-shadow: var(--shadow);
  animation: guide-mascot-float 5s ease-in-out infinite;
}

.guide-panel {
  max-width: var(--max);
  margin: 0 auto 1.5rem;
  padding: 1.5rem 1.25rem 1.75rem;
  background: #fffef9;
  border: 1px solid rgba(240, 98, 146, 0.2);
  border-radius: calc(var(--radius) + 6px);
  box-shadow: 0 4px 24px rgba(240, 98, 146, 0.1);
}

@keyframes guide-mascot-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

.guide-panel__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.25rem;
  margin-bottom: 1.5rem;
}

.guide-panel__mascot {
  margin: 0;
  flex-shrink: 0;
}

.guide-panel__mascot img {
  width: 88px;
  height: 88px;
  object-fit: contain;
  border-radius: 50%;
  background: #fff;
  padding: 4px;
  box-sizing: border-box;
  border: 3px solid #fff;
  outline: 2px solid rgba(240, 98, 146, 0.4);
  box-shadow: var(--shadow-sm);
  animation: guide-mascot-float 5s ease-in-out infinite;
  animation-delay: 0.15s;
}

.guide-panel__head-text {
  min-width: 0;
}

.guide-panel__head-text .section__eyebrow {
  margin-bottom: 0.35rem;
}

.guide-panel__title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--navy);
  line-height: 1.25;
}

.guide-panel__intro {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.55;
  color: var(--text);
  font-weight: 600;
}

.guide-panel__lead {
  margin: 0.45rem 0 0;
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.55;
}

.guide-cards-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  align-items: stretch;
}

.guide-cards-row__card {
  min-width: 0;
}

.guide-cards-row .plan-card {
  margin: 0;
  height: 100%;
}

.guide-cards-row .form-card {
  margin: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.guide-cards-row .form-card .btn {
  margin-top: auto;
}

.guide-cards-row .guide-listing-card {
  margin: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.guide-cards-row .guide-listing-card .card__body {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.guide-cards-row .guide-listing-card .card__footer {
  margin-top: auto;
}

.guide-form-preview .form-section-title {
  font-size: 1rem;
}

.guide-panel--roommate {
  margin-top: 1.25rem;
}

.guide-roommate__shell {
  margin-top: 1.25rem;
}

.guide-roommate__toolbar {
  margin-bottom: 1rem;
}

.guide-roommate__toolbar-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
}

.guide-roommate__form-wrap {
  min-width: 0;
}

.guide-roommate-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr);
  gap: 1.25rem 1.5rem;
  align-items: start;
}

.guide-lifestyle-preview {
  margin: 0;
}

.guide-lifestyle-preview .form-section-title {
  margin-top: 0;
}

.guide-lifestyle-preview__grid {
  gap: 1rem 1.25rem !important;
}

.guide-seg-label {
  margin: 0 0 0.5rem;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.guide-lifestyle-preview__note {
  margin: 1rem 0 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.guide-roommate__side {
  min-width: 0;
}

.guide-roommate__side-title {
  margin: 0 0 0.85rem;
  font-size: 1rem;
  font-weight: 800;
  color: var(--navy);
}

.guide-match-stack {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.guide-roommate__side .match-mini-card {
  margin-bottom: 0;
}

@media (max-width: 1020px) {
  .guide-cards-row {
    grid-template-columns: 1fr;
  }

  .guide-roommate-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .guide-roommate__toolbar-btns .btn {
    flex: 1 1 auto;
    min-width: 140px;
    justify-content: center;
  }
}

/* Waitlist modal (home) */
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: 1.25rem;
}

.modal[hidden] {
  display: none;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(30, 41, 59, 0.45);
  backdrop-filter: blur(4px);
}

.modal__panel {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  max-height: min(90vh, 640px);
  overflow-y: auto;
  background: #fff;
  border-radius: calc(var(--radius) + 4px);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 1.75rem 1.5rem 1.5rem;
}

.modal__close {
  position: absolute;
  top: 0.65rem;
  right: 0.65rem;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: var(--pill);
  background: #f8f4f7;
  color: var(--text-muted);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.modal__close:hover {
  background: var(--bg-pink);
  color: var(--accent-dark);
}

.modal__title {
  margin: 0 0 0.5rem;
  font-size: 1.35rem;
  font-weight: 800;
  color: #6d1f3a;
}

.modal__lede {
  margin: 0 0 1.25rem;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--text);
}

.modal__eyebrow {
  margin: 0 0 0.5rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.modal__stats {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.5rem;
  margin: 0 0 1.35rem;
  padding: 1rem 0.65rem;
  background: #faf7f4;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(93, 64, 55, 0.08);
}

.modal__stat {
  flex: 1;
  min-width: 0;
  text-align: center;
}

.modal__stat-value {
  margin: 0 0 0.4rem;
  font-family: var(--font-accent);
  font-size: clamp(1.05rem, 2.8vw, 1.35rem);
  font-weight: 600;
  font-style: normal;
  color: #e57373;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.modal__stat-label {
  margin: 0;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #5c5560;
  line-height: 1.35;
}

.modal__launch-hint {
  margin: 0 0 1.15rem;
  padding: 0.55rem 0.85rem;
  font-size: 0.9rem;
  line-height: 1.45;
  font-weight: 600;
  color: #5d3545;
  background: linear-gradient(105deg, rgba(240, 98, 146, 0.14) 0%, rgba(255, 248, 252, 0.9) 55%);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--accent);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset;
}

.modal__launch-hint strong {
  color: var(--accent-dark);
  font-weight: 800;
}

.waitlist-form .field {
  margin-bottom: 0.85rem;
}

.modal__success-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 0.75rem;
  border-radius: 50%;
  background: linear-gradient(135deg, #e8f5e9, #fce4ec);
  display: grid;
  place-items: center;
  font-size: 1.5rem;
  color: var(--accent-dark);
}

.waitlist-gform-iframe {
  position: absolute;
  width: 0;
  height: 0;
  border: 0;
  opacity: 0;
  pointer-events: none;
}
