/* ─── SunnyPlaya App — Luxury Resort Design System ───────────────────────── */

:root {
  --white:   #ffffff;
  --navy:    #0b2545;
  --navy-dk: #071a33;
  --gold:    #ddb967;
  --gold-lt: #f0d898;
  --cream:   #faf3e0;
  --cream-dk: #f0e8cb;
  --black:   #111111;
  --gray-3:  #374151;
  --gray-4:  #6b7280;
  --gray-5:  #9ca3af;
  --gray-6:  #d1d5db;
  --gray-7:  #f3f4f6;
  --error:   #dc2626;
  --success: #15803d;

  --border:       rgba(11, 37, 69, 0.12);
  --border-focus: var(--navy);

  --r-sm:  6px;
  --r-md:  10px;
  --r-lg:  16px;
  --r-xl:  24px;
  --r-full: 999px;

  --shadow-sm: 0 1px 4px rgba(11, 37, 69, 0.07);
  --shadow-md: 0 4px 16px rgba(11, 37, 69, 0.10);
  --shadow-lg: 0 8px 40px rgba(11, 37, 69, 0.13);
  --shadow-card: 0 2px 12px rgba(11, 37, 69, 0.08);

  --t: 0.2s ease;

  --font:         "DM Sans", system-ui, sans-serif;
  --font-display: "Playfair Display", Georgia, serif;

  --nav-h: 64px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; -webkit-font-smoothing: antialiased; scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--black);
  background: var(--white);
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

body:has(.sp-nav--provider) {
  --nav-h: 96px;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* ─── Navbar ──────────────────────────────────────────────────────────────── */

.sp-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  height: var(--nav-h);
}

.sp-nav__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.sp-logo {
  display: block;
  width: auto;
  max-width: 100%;
}

.sp-nav__brand {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.sp-nav__logo-img {
  height: 2rem;
}

.sp-nav__links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.sp-nav__link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gray-3);
  padding: 0.4rem 0.75rem;
  border-radius: var(--r-sm);
  transition: color var(--t), background var(--t);
  white-space: nowrap;
}

.sp-nav__link:hover { color: var(--navy); background: var(--cream); }
.sp-nav__link--muted { color: var(--gray-4); }
.sp-nav__link--muted:hover { color: var(--navy); background: var(--cream); }

.sp-nav__link--cta {
  background: var(--navy);
  color: var(--white);
  padding: 0.4rem 1rem;
  border-radius: var(--r-md);
}

.sp-nav__link--cta:hover { background: var(--navy-dk); }

/* Small unread count pill for nav links (Chats etc.) */
/* `display: inline-block` would otherwise beat the [hidden] attribute, so the
   badge must be explicitly hidden when there are no new messages (count 0). */
.sp-nav__count[hidden] {
  display: none;
}

.sp-nav__count {
  display: inline-block;
  min-width: 18px;
  margin-left: 4px;
  padding: 0 5px;
  border-radius: var(--r-full);
  background: #b91c1c;
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  vertical-align: middle;
}

.sp-nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 2.25rem;
  height: 2.25rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  border-radius: var(--r-sm);
  flex-shrink: 0;
}

.sp-nav__toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--navy);
  border-radius: 1px;
  transition: transform var(--t), opacity var(--t);
}

/* ─── Customer navbar ─────────────────────────────────────────────────────── */

.sp-cnav {
  position: sticky;
  top: 0;
  z-index: 120;
  background: var(--white);
  border-bottom: 1px solid var(--border);
}

.sp-cnav__inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0.85rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.sp-cnav__brand {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.sp-cnav__logo-img {
  height: 2.4rem;
}

.sp-cnav__search {
  flex: 1;
  min-width: 0;
  max-width: 34rem;
  position: relative;
}

.sp-cnav__search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  width: 1.1rem;
  height: 1.1rem;
  color: var(--gray-5);
  pointer-events: none;
}

.sp-cnav__search input {
  width: 100%;
  height: 2.75rem;
  padding: 0 1rem 0 2.75rem;
  border: none;
  border-radius: var(--r-full);
  background: var(--gray-7);
  font: inherit;
  font-size: 0.9rem;
  color: var(--navy);
}

.sp-cnav__search input::placeholder {
  color: var(--gray-5);
}

.sp-cnav__search input:focus {
  outline: 2px solid rgba(11, 37, 69, 0.12);
  background: var(--white);
  box-shadow: inset 0 0 0 1px var(--gray-6);
}

.sp-cnav__actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-left: auto;
  flex-shrink: 0;
}

.sp-cnav__action {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.7rem;
  border-radius: var(--r-md);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gray-3);
  white-space: nowrap;
  transition: color var(--t), background var(--t);
}

.sp-cnav__action:hover {
  color: var(--navy);
  background: var(--gray-7);
}

.sp-cnav__action svg {
  width: 1rem;
  height: 1rem;
}

.sp-cnav__favorites-label {
  position: relative;
  display: inline-block;
}

.sp-cnav__action--favorites .sp-cnav__badge {
  position: absolute;
  top: -0.8rem;
  right: -0.8rem;
  min-width: 1.1rem;
  height: 1.1rem;
  padding: 0;
  border-radius: var(--r-full);
  background: var(--gold);
  color: var(--navy);
  font-size: 0.625rem;
  font-weight: 700;
  line-height: 1.1rem;
  text-align: center;
}

.sp-cnav__lang {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.7rem;
  border: none;
  border-radius: var(--r-md);
  background: transparent;
  box-shadow: none;
  font: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--gray-3);
  cursor: pointer;
  white-space: nowrap;
  transition: color var(--t), background var(--t);
}

.sp-cnav__lang:hover {
  color: var(--navy);
  background: var(--gray-7);
}

.sp-cnav__lang-icon {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
  color: currentColor;
}

.sp-cnav__lang-code {
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1;
}

.sp-cnav__user {
  position: relative;
}

.sp-cnav__avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border: none;
  border-radius: 50%;
  background: var(--navy);
  color: var(--white);
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  cursor: pointer;
  overflow: hidden;
  padding: 0;
}

.sp-cnav__avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
}

.sp-cnav__menu {
  position: absolute;
  top: calc(100% + 0.65rem);
  right: 0;
  width: 15.5rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.sp-cnav__menu-header {
  padding: 1rem 1rem 0.85rem;
  border-bottom: 1px solid var(--border);
}

.sp-cnav__menu-header strong {
  display: block;
  font-size: 0.9375rem;
  color: var(--navy);
  margin-bottom: 0.15rem;
}

.sp-cnav__menu-header span {
  display: block;
  font-size: 0.8125rem;
  color: var(--gray-4);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sp-cnav__menu-list {
  list-style: none;
  padding: 0.4rem;
}

.sp-cnav__menu-list a {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.65rem 0.75rem;
  border-radius: var(--r-md);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gray-3);
  transition: background var(--t), color var(--t);
}

.sp-cnav__menu-list a:hover {
  background: var(--gray-7);
  color: var(--navy);
}

.sp-cnav__menu-list svg {
  width: 1.05rem;
  height: 1.05rem;
  flex-shrink: 0;
}

.sp-cnav__menu-logout {
  color: var(--error) !important;
}

.sp-cnav__menu-logout:hover {
  background: #fef2f2 !important;
  color: #b91c1c !important;
}

.sp-cnav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 2.25rem;
  height: 2.25rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  border-radius: var(--r-sm);
  flex-shrink: 0;
}

.sp-cnav__toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--navy);
  border-radius: 1px;
}

.sp-cnav__auth-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 2.5rem;
  padding: 0 1.15rem;
  border-radius: var(--r-full);
  background: var(--gold);
  color: var(--navy);
  font-size: 0.875rem;
  font-weight: 700;
  white-space: nowrap;
  transition: background var(--t), transform 0.15s ease;
}

.sp-cnav__auth-btn:hover {
  background: var(--gold-lt);
  color: var(--navy);
}

/* ─── Main / Footer ───────────────────────────────────────────────────────── */

.sp-main {
  flex: 1;
  min-height: 0;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.sp-site-footer {
  margin-top: auto;
  background: var(--white);
  border-top: 1px solid var(--border);
  color: var(--navy);
}

.sp-site-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3.5rem 1.5rem 2rem;
}

.sp-site-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 2.5rem 2rem;
  padding-bottom: 2.5rem;
}

.sp-site-footer__brand {
  display: inline-flex;
  align-items: center;
}

.sp-site-footer__logo-img {
  height: 2.75rem;
}

.sp-site-footer__tagline {
  margin-top: 1rem;
  max-width: 22rem;
  font-size: 0.9375rem;
  line-height: 1.65;
  color: var(--gray-4);
}

.sp-site-footer__contact {
  list-style: none;
  margin-top: 1.25rem;
  display: grid;
  gap: 0.65rem;
}

.sp-site-footer__contact li {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.875rem;
  color: var(--gray-3);
}

.sp-site-footer__contact svg {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
  color: var(--navy);
}

.sp-site-footer__contact a:hover {
  color: var(--navy);
  text-decoration: underline;
}

.sp-site-footer__heading {
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 1rem;
}

.sp-site-footer__links {
  list-style: none;
  display: grid;
  gap: 0.55rem;
}

.sp-site-footer__links a {
  font-size: 0.875rem;
  color: var(--gray-4);
  transition: color var(--t);
}

.sp-site-footer__links a:hover {
  color: var(--navy);
}

.sp-site-footer__newsletter {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.35rem 1.5rem;
  border: 1px solid var(--gray-6);
  border-radius: var(--r-xl);
  background: var(--gray-7);
  margin-bottom: 2rem;
}

.sp-site-footer__newsletter-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.25rem;
}

.sp-site-footer__newsletter-sub {
  font-size: 0.875rem;
  color: var(--gray-4);
}

.sp-site-footer__newsletter-form {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.sp-site-footer__newsletter-form input {
  width: min(18rem, 100%);
  height: 2.75rem;
  padding: 0 1rem;
  border: 1px solid var(--gray-6);
  border-radius: var(--r-full);
  background: var(--white);
  font: inherit;
  font-size: 0.875rem;
  color: var(--navy);
}

.sp-site-footer__newsletter-form input::placeholder {
  color: var(--gray-5);
}

.sp-site-footer__newsletter-form input:focus {
  outline: none;
  border-color: var(--navy);
}

.sp-site-footer__newsletter-form button {
  height: 2.75rem;
  padding: 0 1.35rem;
  border: none;
  border-radius: var(--r-full);
  background: var(--navy);
  color: var(--white);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--t);
}

.sp-site-footer__newsletter-form button:hover {
  background: var(--navy-dk);
}

.sp-site-footer__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
}

.sp-site-footer__copy {
  font-size: 0.8125rem;
  color: var(--gray-4);
}

.sp-site-footer__legal {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.sp-site-footer__legal a {
  font-size: 0.8125rem;
  color: var(--gray-4);
  transition: color var(--t);
}

.sp-site-footer__legal a:hover {
  color: var(--navy);
}

.sp-site-footer__social {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.sp-site-footer__social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--navy);
  color: var(--white);
  transition: background var(--t), transform 0.15s ease;
}

.sp-site-footer__social a:hover {
  background: var(--navy-dk);
  transform: translateY(-1px);
}

.sp-site-footer__social svg {
  width: 1rem;
  height: 1rem;
}

@media (max-width: 960px) {
  .sp-site-footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .sp-site-footer__brand-col {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .sp-site-footer__inner {
    padding-top: 2.5rem;
  }

  .sp-site-footer__grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .sp-site-footer__newsletter {
    flex-direction: column;
    align-items: stretch;
  }

  .sp-site-footer__newsletter-form {
    flex-direction: column;
    align-items: stretch;
  }

  .sp-site-footer__newsletter-form input,
  .sp-site-footer__newsletter-form button {
    width: 100%;
  }

  .sp-site-footer__bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .sp-site-footer__legal,
  .sp-site-footer__social {
    width: 100%;
  }
}

/* ─── Page wrapper ────────────────────────────────────────────────────────── */

.sp-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

.sp-page--narrow {
  max-width: 740px;
}

/* ─── Section hero ────────────────────────────────────────────────────────── */

.sp-hero {
  background: var(--navy);
  color: var(--white);
  padding: 3.5rem 1.5rem;
  text-align: center;
}

.sp-hero__inner { max-width: 1200px; margin: 0 auto; }

.sp-hero__eyebrow {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.sp-hero__title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}

.sp-hero__sub {
  font-size: 1rem;
  color: rgba(255,255,255,0.7);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ─── Typography helpers ──────────────────────────────────────────────────── */

.sp-display {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--navy);
}

.sp-eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
}

/* ─── Badges ─────────────────────────────────────────────────────────────── */

.sp-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.25rem 0.625rem;
  border-radius: var(--r-full);
  font-size: 0.75rem;
  font-weight: 600;
}

.sp-badge--navy   { background: var(--navy); color: var(--white); }
.sp-badge--gold   { background: var(--gold); color: var(--navy); }
.sp-badge--cream  { background: var(--cream); color: var(--navy); border: 1px solid var(--cream-dk); }
.sp-badge--green  { background: #dcfce7; color: #15803d; border: 1px solid #bbf7d0; }
.sp-badge--gray   { background: var(--gray-7); color: var(--gray-4); border: 1px solid var(--gray-6); }
.sp-badge--orange { background: #fff7ed; color: #c2410c; border: 1px solid #fed7aa; }
.sp-badge--red    { background: #fef2f2; color: #b91c1c; border: 1px solid #fecaca; }

/* ─── Buttons ────────────────────────────────────────────────────────────── */

.sp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.6rem 1.25rem;
  border-radius: var(--r-md);
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: background var(--t), box-shadow var(--t), transform 0.1s ease, border-color var(--t);
  text-decoration: none;
  white-space: nowrap;
}

.sp-btn:active { transform: scale(0.985); }

.sp-btn--primary { background: var(--navy); color: var(--white); }
.sp-btn--primary:hover { background: var(--navy-dk); box-shadow: 0 4px 14px rgba(11, 37, 69, 0.22); }

.sp-btn--gold { background: var(--gold); color: var(--navy); }
.sp-btn--gold:hover { background: var(--gold-lt); box-shadow: 0 4px 14px rgba(221, 185, 103, 0.35); }

.sp-btn--ghost {
  background: transparent;
  color: var(--navy);
  border: 1.5px solid var(--border);
}
.sp-btn--ghost:hover { background: var(--cream); border-color: rgba(11, 37, 69, 0.22); }

.sp-btn--danger { background: #fef2f2; color: var(--error); border: 1.5px solid #fecaca; }
.sp-btn--danger:hover { background: #fee2e2; }

.sp-btn--sm { padding: 0.4rem 0.875rem; font-size: 0.8125rem; border-radius: var(--r-sm); }
.sp-btn--lg { padding: 0.875rem 1.75rem; font-size: 1rem; border-radius: var(--r-lg); }
.sp-btn--full { width: 100%; }

/* ─── Cards ──────────────────────────────────────────────────────────────── */

.sp-card {
  background: var(--white);
  border: 1px solid rgba(193, 163, 123, 0.16);
  border-radius: 12px;
  padding: 0.7rem;
  box-shadow: 0 2px 12px rgba(17, 17, 17, 0.05);
  transition: box-shadow var(--t), transform var(--t);
  display: flex;
  flex-direction: column;
}

.sp-card:hover {
  box-shadow: 0 8px 24px rgba(17, 17, 17, 0.09);
  transform: translateY(-2px);
}

.sp-card__media {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
}

.sp-card__media-link {
  display: block;
  color: inherit;
}

.sp-card__content {
  display: flex;
  flex-direction: column;
  padding: 0.95rem 0.35rem 0.45rem;
}

.sp-card__title-link {
  color: inherit;
  text-decoration: none;
}

.sp-card__title-link:hover .sp-card__title {
  color: var(--navy);
}

.sp-favorite-btn {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: var(--white);
  color: var(--black);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow var(--t);
}

.sp-favorite-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.sp-favorite-btn svg {
  width: 1rem;
  height: 1rem;
}

.sp-favorite-btn.is-active {
  color: #e11d48;
}

.sp-favorite-btn.is-active svg {
  fill: currentColor;
}

.sp-card__img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: var(--cream);
  display: block;
}

.sp-card__img-placeholder {
  width: 100%;
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, var(--cream) 0%, var(--cream-dk) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
}

.sp-card__img-placeholder svg { width: 3rem; height: 3rem; opacity: 0.5; }

.sp-card__title {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--black);
  line-height: 1.25;
  margin-bottom: 0.65rem;
}

.sp-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}

.sp-card__head .sp-card__title-link {
  min-width: 0;
}

.sp-card__head .sp-card__title {
  margin-bottom: 0;
}

/* "ab X € / Nacht" starting price next to the title. */
.sp-card__price {
  flex-shrink: 0;
  text-align: right;
  line-height: 1.15;
  white-space: nowrap;
}

.sp-card__price-from {
  display: block;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gray-4);
}

.sp-card__price-amount {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--black);
}

.sp-card__price-unit {
  font-size: 0.68rem;
  font-weight: 500;
  color: var(--gray-3);
}

/* Total for the chosen stay, shown once the homepage filter has a date range.
   Understated: a thin divider, muted duration on the left, bold total on the
   right — no background box. */
.sp-card__stay {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0.1rem 0 0.7rem;
  padding-top: 0.6rem;
  border-top: 1px solid rgba(193, 163, 123, 0.22);
}

.sp-card__stay-meta {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--gray-3);
}

.sp-card__stay-total {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--black);
  white-space: nowrap;
}

.sp-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.sp-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1rem;
  min-width: 0;
}

.sp-card__meta-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--gray-3);
  white-space: nowrap;
}

.sp-card__meta-item svg {
  width: 0.9rem;
  height: 0.9rem;
  color: var(--gray-4);
  flex-shrink: 0;
}

.sp-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  flex-shrink: 0;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  color: #c1a37b;
  transition: color var(--t);
}

.sp-card__cta:hover {
  color: #a88758;
}

.sp-card__cta svg {
  width: 0.8rem;
  height: 0.8rem;
}

@media (max-width: 640px) {
  .sp-card__footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.65rem;
  }

  .sp-card__cta {
    align-self: flex-end;
  }
}

/* ─── Card grid ───────────────────────────────────────────────────────────── */

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

/* ─── Empty state ─────────────────────────────────────────────────────────── */

.sp-empty {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--gray-4);
  background: var(--cream);
  border-radius: var(--r-lg);
  border: 1.5px dashed var(--cream-dk);
}

.sp-empty__icon {
  width: 3rem;
  height: 3rem;
  margin: 0 auto 1rem;
  color: var(--gold);
  opacity: 0.6;
}

.sp-empty__title {
  font-family: var(--font-display);
  font-size: 1.125rem;
  color: var(--navy);
  margin-bottom: 0.4rem;
}

.sp-empty p { font-size: 0.875rem; }

/* ─── Divider ─────────────────────────────────────────────────────────────── */

.sp-divider {
  height: 1px;
  background: var(--border);
  margin: 1.75rem 0;
}

/* ─── Back link ───────────────────────────────────────────────────────────── */

.sp-back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gray-4);
  margin-bottom: 1.5rem;
  transition: color var(--t);
}

.sp-back:hover { color: var(--navy); }
.sp-back svg { width: 1rem; height: 1rem; }

/* ─── Stats row ───────────────────────────────────────────────────────────── */

.sp-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.sp-stat {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.875rem;
  background: var(--cream);
  border-radius: var(--r-full);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--navy);
  border: 1px solid var(--cream-dk);
}

.sp-stat svg { width: 0.875rem; height: 0.875rem; color: var(--gold); }

/* ─── Section heading ─────────────────────────────────────────────────────── */

.sp-section-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.875rem;
  padding-bottom: 0.625rem;
  border-bottom: 2px solid var(--gold);
  display: inline-block;
}

/* ─── Info list ───────────────────────────────────────────────────────────── */

.sp-info-list {
  list-style: none;
  display: grid;
  gap: 0.625rem;
}

.sp-info-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--gray-3);
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
}

.sp-info-list li:last-child { border-bottom: none; }

.sp-info-list__label {
  font-weight: 600;
  color: var(--navy);
  min-width: 160px;
  flex-shrink: 0;
}

/* ─── Amenities chips ─────────────────────────────────────────────────────── */

.sp-amenities {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.sp-amenity {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.35rem 0.75rem;
  background: var(--cream);
  border: 1px solid var(--cream-dk);
  border-radius: var(--r-full);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--navy);
}

/* ─── Pricing box ─────────────────────────────────────────────────────────── */

.sp-price-box {
  background: var(--navy);
  border-radius: var(--r-lg);
  padding: 1.5rem;
  color: var(--white);
}

.sp-price-box__main {
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
  margin-bottom: 1rem;
}

.sp-price-box__amount {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--gold);
}

.sp-price-box__unit { font-size: 0.875rem; color: rgba(255,255,255,0.65); }

.sp-price-box__rows { list-style: none; margin-bottom: 1.25rem; }

.sp-price-box__rows li {
  display: flex;
  justify-content: space-between;
  font-size: 0.8125rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.8);
}

.sp-price-box__rows li:last-child { border-bottom: none; }

/* ─── Detail layout ───────────────────────────────────────────────────────── */

.sp-detail {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
}

.sp-detail__hero-img {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
  background: var(--cream);
  display: block;
}

.sp-detail__hero-placeholder {
  width: 100%;
  height: 340px;
  background: linear-gradient(135deg, var(--cream) 0%, var(--cream-dk) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.sp-detail__header { padding: 2rem 0 0; }

.sp-detail__body {
  display: grid;
  gap: 2.5rem;
  grid-template-columns: 1fr;
}

.sp-detail__section { }

.sp-detail__text {
  font-size: 0.9375rem;
  line-height: 1.75;
  color: var(--gray-3);
}

/* ─── Provider dashboard ───────────────────────────────────────────────────── */

.sp-dashboard-header {
  background: var(--navy);
  color: var(--white);
  padding: 2.5rem 1.5rem;
}

.sp-dashboard-header__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.sp-dashboard-header__eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.4rem;
}

.sp-dashboard-header__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  font-weight: 700;
  line-height: 1.1;
}

/* ─── Dashboard apartment card ─────────────────────────────────────────────── */

.sp-apt-row {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.125rem 1.25rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  transition: box-shadow var(--t);
}

.sp-apt-row:hover { box-shadow: var(--shadow-md); }

.sp-apt-row__thumb {
  width: 80px;
  height: 64px;
  border-radius: var(--r-sm);
  object-fit: cover;
  background: var(--cream);
  flex-shrink: 0;
}

.sp-apt-row__thumb-placeholder {
  width: 80px;
  height: 64px;
  border-radius: var(--r-sm);
  background: linear-gradient(135deg, var(--cream), var(--cream-dk));
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
}

.sp-apt-row__thumb-placeholder svg { width: 1.5rem; height: 1.5rem; opacity: 0.5; }

.sp-apt-row__info { flex: 1; min-width: 0; }

.sp-apt-row__title {
  font-weight: 600;
  color: var(--navy);
  font-size: 0.9375rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 0.2rem;
}

.sp-apt-row__meta {
  font-size: 0.8125rem;
  color: var(--gray-4);
}

.sp-apt-row__price {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--navy);
  flex-shrink: 0;
  text-align: right;
}

.sp-apt-row__actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.sp-apt-list { display: grid; gap: 0.75rem; }

/* ─── Form shell ──────────────────────────────────────────────────────────── */

.sp-form-page {
  background: var(--gray-7);
  min-height: calc(100dvh - var(--nav-h));
}

.sp-form-shell {
  max-width: 840px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

.sp-form-hero {
  margin-bottom: 2rem;
}

.sp-form-hero__back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8125rem;
  color: var(--gray-4);
  margin-bottom: 1rem;
  transition: color var(--t);
}

.sp-form-hero__back:hover { color: var(--navy); }
.sp-form-hero__back svg { width: 0.875rem; height: 0.875rem; }

.sp-form-hero__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.sp-form-hero__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  color: var(--navy);
  line-height: 1.15;
}

/* ─── Form panels ─────────────────────────────────────────────────────────── */

.sp-form { display: grid; gap: 1.25rem; }

.sp-panel {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
}

.sp-panel__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
  background: var(--cream);
}

.sp-panel__header-left { }

.sp-panel__title {
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.2rem;
}

.sp-panel__sub {
  font-size: 0.8125rem;
  color: var(--gray-4);
  line-height: 1.5;
}

.sp-panel__body { padding: 1.5rem; }

/* Django form fields in panels */
.sp-panel__body p {
  display: grid;
  gap: 0.3rem;
  margin-bottom: 1.125rem;
}

.sp-panel__body p:last-child { margin-bottom: 0; }

.sp-panel__body label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--navy);
}

.sp-panel__body input,
.sp-panel__body select,
.sp-panel__body textarea {
  width: 100%;
  max-width: 100%;
  padding: 0.6rem 0.875rem;
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  font-family: var(--font);
  font-size: 0.875rem;
  color: var(--black);
  background: var(--white);
  outline: none;
  transition: border-color var(--t), box-shadow var(--t);
  box-sizing: border-box;
}

.sp-panel__body input[type="checkbox"] {
  width: auto;
  accent-color: var(--navy);
}

.sp-panel__body input:focus,
.sp-panel__body select:focus,
.sp-panel__body textarea:focus {
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(11, 37, 69, 0.07);
}

.sp-panel__body textarea { resize: vertical; min-height: 100px; }

.sp-panel__body .helptext {
  font-size: 0.75rem;
  color: var(--gray-4);
}

.sp-panel__body .errorlist {
  list-style: none;
  font-size: 0.75rem;
  color: var(--error);
}

/* ─── Inline formsets ─────────────────────────────────────────────────────── */

.sp-inline-list { display: grid; gap: 0.75rem; }

.sp-inline {
  background: var(--gray-7);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 1rem 1.125rem;
}

.sp-inline__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.875rem;
}

.sp-inline__title {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--navy);
}

.sp-inline p {
  display: grid;
  gap: 0.25rem;
  margin-bottom: 0.75rem;
}

.sp-inline p:last-child { margin-bottom: 0; }

.sp-inline label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--navy);
}

.sp-inline input,
.sp-inline select,
.sp-inline textarea {
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  font-family: var(--font);
  font-size: 0.8125rem;
  color: var(--black);
  background: var(--white);
  outline: none;
  transition: border-color var(--t), box-shadow var(--t);
  box-sizing: border-box;
}

.sp-inline input[type="checkbox"] { width: auto; accent-color: var(--navy); }

.sp-inline input:focus,
.sp-inline select:focus,
.sp-inline textarea:focus {
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(11, 37, 69, 0.07);
}

.sp-inline .helptext { font-size: 0.72rem; color: var(--gray-4); }
.sp-inline .errorlist { list-style: none; font-size: 0.72rem; color: var(--error); }

.sp-empty-inline {
  border: 1.5px dashed var(--border);
  border-radius: var(--r-md);
  padding: 1.25rem;
  text-align: center;
  font-size: 0.8125rem;
  color: var(--gray-4);
}

/* ─── Form actions ────────────────────────────────────────────────────────── */

.sp-form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
  padding-top: 0.5rem;
}

/* ─── Delete confirm ──────────────────────────────────────────────────────── */

.sp-confirm {
  max-width: 480px;
  margin: 4rem auto;
  padding: 0 1.5rem;
  text-align: center;
}

.sp-confirm__icon {
  width: 3.5rem;
  height: 3.5rem;
  margin: 0 auto 1.25rem;
  background: #fef2f2;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--error);
}

.sp-confirm__icon svg { width: 1.75rem; height: 1.75rem; }

.sp-confirm__title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--navy);
  margin-bottom: 0.5rem;
}

.sp-confirm__text {
  font-size: 0.9375rem;
  color: var(--gray-4);
  margin-bottom: 1.75rem;
  line-height: 1.6;
}

.sp-confirm__name {
  font-weight: 700;
  color: var(--navy);
}

.sp-confirm__actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ─── Legacy inline messages (auth card fallback) ─────────────────────────── */

.auth-messages { list-style: none; max-width: 1200px; margin: 0.75rem auto 0; padding: 0 1.5rem; }

.auth-message {
  padding: 0.65rem 0.875rem;
  border-radius: var(--r-sm);
  font-size: 0.8125rem;
  margin-bottom: 0.4rem;
}

.auth-message--error   { background: #fef2f2; color: var(--error); border: 1px solid #fecaca; }
.auth-message--success { background: #f0fdf4; color: var(--success); border: 1px solid #bbf7d0; }
.auth-message--info    { background: var(--cream); color: var(--navy); border: 1px solid rgba(221,185,103,0.4); }
.auth-message--warning { background: #fffbeb; color: #92400e; border: 1px solid #fde68a; }

/* ─── Responsive ──────────────────────────────────────────────────────────── */

@media (min-width: 768px) {
  .sp-detail__body {
    grid-template-columns: 1fr 320px;
  }
}

@media (max-width: 1023px) {
  .sp-cnav__search {
    display: none;
    order: 3;
    flex: 1 1 100%;
    max-width: none;
  }

  .sp-cnav__inner:has(.sp-cnav__actions.is-open) .sp-cnav__search {
    display: block;
  }

  .sp-cnav__inner {
    flex-wrap: wrap;
  }

  .sp-cnav__actions {
    display: none;
  }

  .sp-cnav__actions.is-open {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    order: 4;
    flex: 1 1 100%;
    gap: 0.35rem;
    padding-top: 0.35rem;
    border-top: 1px solid var(--border);
  }

  .sp-cnav__action,
  .sp-cnav__lang,
  .sp-cnav__auth-btn {
    justify-content: flex-start;
  }

  .sp-cnav__auth-btn {
    width: 100%;
  }

  .sp-cnav__user {
    width: 100%;
  }

  .sp-cnav__avatar {
    width: 100%;
    border-radius: var(--r-md);
    height: 2.5rem;
  }

  .sp-cnav__menu {
    position: static;
    width: 100%;
    margin-top: 0.5rem;
    box-shadow: none;
  }

  .sp-cnav__toggle {
    display: flex;
    margin-left: auto;
  }
}

@media (max-width: 767px) {
  body:has(.sp-nav--provider) {
    --nav-h: 80px;
  }

  .sp-nav__links { display: none; }
  .sp-nav__links.is-open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    padding: 0.75rem 1.5rem 1rem;
    gap: 0.25rem;
    box-shadow: var(--shadow-md);
    z-index: 99;
  }

  .sp-nav { position: sticky; }
  .sp-nav__toggle { display: flex; }

  .sp-apt-row { flex-wrap: wrap; }
  .sp-apt-row__actions { width: 100%; }

  .sp-form-actions { flex-direction: column-reverse; }
  .sp-form-actions .sp-btn { width: 100%; }

  .sp-dashboard-header__inner { flex-direction: column; align-items: flex-start; }

  .sp-detail__hero-img { max-height: 280px; }
}

@media (min-width: 1024px) {
  .sp-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ─── Language modal ──────────────────────────────────────────────────────── */

body.sp-lang-modal-open {
  overflow: hidden;
}

.sp-lang-modal[hidden] {
  display: none;
}

.sp-lang-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.sp-lang-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(11, 37, 69, 0.45);
  backdrop-filter: blur(4px);
}

.sp-lang-modal__dialog {
  position: relative;
  width: min(100%, 34rem);
  max-height: min(90vh, 40rem);
  overflow: auto;
  border-radius: var(--r-lg);
  background: var(--white);
  box-shadow: var(--shadow-lg);
}

.sp-lang-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.15rem 1.35rem;
  border-bottom: 1px solid var(--border);
}

.sp-lang-modal__title {
  margin: 0;
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--black);
}

.sp-lang-modal__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border: none;
  border-radius: var(--r-full);
  background: transparent;
  color: var(--gray-4);
  cursor: pointer;
  transition: background var(--t), color var(--t);
}

.sp-lang-modal__close:hover {
  background: var(--gray-7);
  color: var(--navy);
}

.sp-lang-modal__close svg {
  width: 1.1rem;
  height: 1.1rem;
}

.sp-lang-modal__body {
  padding: 1.15rem 1.35rem 1.35rem;
}

.sp-lang-modal__section + .sp-lang-modal__section {
  margin-top: 1.35rem;
}

.sp-lang-modal__section-title {
  margin: 0 0 0.75rem;
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--gray-4);
}

.sp-lang-modal__grid {
  display: grid;
  gap: 0.25rem;
}

.sp-lang-modal__grid--all {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 520px) {
  .sp-lang-modal__grid--all {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.sp-lang-modal__option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.7rem 0.8rem;
  border: none;
  border-radius: 0.5rem;
  background: transparent;
  font: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--black);
  text-align: left;
  cursor: pointer;
  transition: background var(--t);
}

.sp-lang-modal__option:hover,
.sp-lang-modal__option.is-selected {
  background: #f3f4f6;
}

.sp-lang-modal__flag {
  display: block;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: var(--r-full);
  object-fit: cover;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.18);
  flex-shrink: 0;
}

.sp-lang-modal__label {
  line-height: 1.3;
}
