/* =========================================================
   RESET & BASE LAYOUT
========================================================= */
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell,
    'Helvetica Neue', Arial, 'Noto Sans', 'Apple Color Emoji','Segoe UI Emoji', sans-serif;
  color: #111;
  background: #fafafa;
}
a { color: inherit; text-decoration: none; }
.container { max-width: 1120px; margin: 0 auto; padding: 20px; }

/* =========================================================
   HEADER
========================================================= */
.header {
  position: sticky; top: 0;
  background: #fff; border-bottom: 1px solid #eee; z-index: 50;
}
.header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px;
}
.brand { font-weight: 800; letter-spacing: .5px; font-size: 20px; }
.nav a {
  margin-left: 16px; padding: 8px 12px; border-radius: 12px;
}
.nav a:hover { background: #f3f4f6; }

/* =========================================================
   CARDS (Home pinned listings)
========================================================= */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}
.card {
  background: #fff; border: 1px solid #eee; border-radius: 18px;
  padding: 16px; display: flex; flex-direction: column; gap: 10px;
  box-shadow: 0 1px 0 rgba(0,0,0,.02);
}
.card h3 { margin: 0; font-size: 18px; }
.price { font-size: 22px; font-weight: 800; }
.badge {
  display: inline-block; background: #eef2ff; color: #3730a3;
  border-radius: 999px; padding: 4px 10px; font-size: 12px; font-weight: 700;
}
.options { display: flex; gap: 8px; }
.option {
  flex: 1; border: 1px solid #e5e7eb; border-radius: 12px;
  padding: 8px; text-align: center; cursor: pointer;
}
.option.active { border-color: #111; background: #111; color: #fff; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: none; background: #111; color: #fff;
  padding: 10px 14px; border-radius: 12px; cursor: pointer; font-weight: 700;
}
.btn.secondary { background: #f3f4f6; color: #111; }
.btn:disabled { opacity: .6; cursor: not-allowed; }

/* =========================================================
   LISTINGS (Admin + public listings)
========================================================= */
.listing {
  background: #fff; border: 1px solid #eee; border-radius: 16px;
  padding: 16px; margin-bottom: 12px;
}
.listing .meta {
  display: flex; gap: 10px; flex-wrap: wrap;
  color: #555; font-size: 14px;
}
.contact {
  background: #f9fafb; border: 1px dashed #e5e7eb;
  padding: 10px; border-radius: 12px; margin-top: 8px; font-size: 14px;
}

/* =========================================================
   FOOTER
========================================================= */
.footer { text-align: center; padding: 30px; color: #666; }

/* =========================================================
   FILM REEL SLIDER (Homepage moving titles)
========================================================= */
.reel { overflow: hidden; background: #0f172a; padding: 10px 0; }
.reel .track {
  display: flex; gap: 24px; white-space: nowrap;
  animation: scroll 30s linear infinite;
}
.reel .frame {
  color: #e2e8f0; font-weight: 700; font-size: 14px;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 999px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
}
@keyframes scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* =========================================================
   FORMS
========================================================= */
.input, select {
  width: 100%; padding: 10px 12px;
  border: 1px solid #e5e7eb; border-radius: 5px;
}
.label { font-weight: 700; font-size: 14px; margin-bottom: 6px; display: block; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
fieldset { border: 1px solid #e5e7eb; border-radius: 16px; padding: 14px; }
legend { font-weight: 800; padding: 0 8px; }
.notice {
  background: #ecfeff; border: 1px solid #a5f3fc;
  padding: 10px 12px; border-radius: 12px;
}
.hidden { display: none !important; }



/* =========================================================
   LOGIN PAGE (Admin)
========================================================= */
.login-page {
  margin: 0; height: 100vh;
  display: flex; justify-content: center; align-items: center;
  background: url('../admin/images/bg.jpg') no-repeat center/cover;
}
.login-container {
  width: 90%; max-width: 800px; height: 60vh;
  display: flex; background: #fff; border-radius: 1px; overflow: hidden;
  box-shadow: 0 8px 30px rgba(0,0,0,0.2);
}
.login-box {
  flex: 1; padding: 40px;
  display: flex; flex-direction: column; justify-content: center;
}
.login-box h1 { margin: 0 0 10px; font-size: 28px; }
.login-box .subtitle { margin-bottom: 20px; color: #555; font-weight: 500; }

.slider { flex: 1; position: relative; overflow: hidden; }
.slide {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  background-size: cover; background-position: center;
  opacity: 0; transition: opacity .8s ease;
  display: flex; align-items: flex-start; justify-content: center;
  padding-top: 40px;
}
.slide.active { opacity: 1; }
.slide .overlay {
  background: rgba(0,0,0,0.5); color: #fff;
  padding: 12px 20px; border-radius: 1px; font-size: 16px;
  text-align: center; max-width: 80%;
}

/* Background videos for login */
.bg-video {
  position: fixed; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
  z-index: -2; opacity: 0;
  transition: opacity 1.6s linear; /* must match JS FADE */
  background: #000; /* fallback */
}
.bg-video.show { opacity: 1; }

/* Overlay for login readability */
.login-page::before {
  content: ""; position: fixed; inset: 0;
  background: rgba(0,0,0,.55); z-index: -1;
}

/* =========================================================
   404 PAGE
========================================================= */
.error-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100vh;
  text-align: center;
  color: #333;
}

.error-box h1 {
  font-size: 5rem;
  font-weight: 800;
  margin: 0;
  color: #dc2626; /* red accent */
}

.error-box p {
  font-size: 1.25rem;
  margin: 10px 0;
  color: #555;
}
