/* ==========================================================================
   Casa Vista — IPS Exhibition 2026
   Single-family type system (Jost), monochrome black &amp; white palette
   ========================================================================== */

:root{
  --ink:            #0e1013;
  --ink-soft:       #1a1d22;
  --cream:          #f5f1e6;
  --cream-dim:      rgba(245,241,230,0.72);
  --cream-faint:    rgba(245,241,230,0.45);
  --accent:         #ffffff;
  --accent-hover:   #dcdcdc;
  --accent-dim:     rgba(255,255,255,0.35);
  --hairline:       rgba(245,241,230,0.22);

  --font: 'Jost', 'Segoe UI', system-ui, sans-serif;

  --edge: clamp(18px, 4vw, 48px);
}

*{ box-sizing: border-box; }

html{ scroll-behavior: smooth; }

body{
  margin: 0;
  font-family: var(--font);
  background: var(--ink);
  color: var(--cream);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

button{ font-family: inherit; }

/* Focus visibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
label:focus-visible{
  outline: 1.5px solid var(--accent-hover);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce){
  *{ animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ---- signature: thin inset frame, like an invitation card ---- */
.frame-border{
  position: fixed;
  inset: 10px;
  border: 1px solid var(--accent-dim);
  pointer-events: none;
  z-index: 40;
}
@media (max-width: 575.98px){
  .frame-border{ inset: 6px; }
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero{
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  isolation: isolate;
}

.hero__media{
  position: fixed;
  inset: 0;
  z-index: -1;
}
.hero__img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Focal point: building + pool corner. Re-aimed per breakpoint below so the
     crop stays on the pool/lifestyle scene instead of drifting onto plain
     glass facade (narrow screens) or the roadway (very wide screens). */
  object-position: 20% 55%;
}
.hero__scrim{
  position: absolute;
  inset: 0;
  /* Left-right layer keeps the image side lighter and the text side (right,
     on desktop) darker. Top-bottom layer darkens steadily with no light
     "dip" partway down — a dip there was washing out the subhead/body copy
     against bright glass/foliage at every width, not just mobile. */
  background:
    linear-gradient(90deg, rgba(10,11,13,0.12) 0%, rgba(10,11,13,0.24) 42%, rgba(10,11,13,0.52) 68%, rgba(10,11,13,0.68) 100%),
    linear-gradient(180deg, rgba(10,11,13,0.30) 0%, rgba(10,11,13,0.36) 25%, rgba(10,11,13,0.46) 50%, rgba(10,11,13,0.54) 75%, rgba(10,11,13,0.62) 100%);
}

/* ---- top bar / logo lockup: Casa Vista top-left, IPS top-right ---- */
.hero__topbar{
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: clamp(20px, 3.4vw, 40px) var(--edge) 0;
}

.hero__topbar-ips{
  height: clamp(36px, 4.2vw, 50px);
  width: auto;
  filter: drop-shadow(0 1px 6px rgba(0,0,0,0.35));
}

.brandmark{
  display: flex;
  align-items: center;
  gap: clamp(16px, 2vw, 24px);
}

.brandmark__cv{
  display: flex;
  align-items: center;
  gap: 12px;
}

.brandmark__cv-icon{
  height: clamp(36px, 4.2vw, 50px);
  width: auto;
}

.brandmark__cv-text{
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brandmark__cv-name{
  font-size: clamp(15px, 1.6vw, 18px);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cream);
}

.brandmark__cv-sub{
  font-size: clamp(9px, 0.95vw, 10.5px);
  font-weight: 300;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--accent-hover);
}

/* ---- hero content ---- */
.hero__content{
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  align-items: center;
  min-width: 0;
  padding: clamp(28px, 6vh, 40px) var(--edge) clamp(48px, 8vh, 72px);
}

.hero__inner{
  max-width: 620px;
  margin-left: auto;
  min-width: 0;
}

.eyebrow{
  margin: 0 0 6px;
  font-size: clamp(13px, 1.3vw, 16px);
  font-weight: 300;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--cream-dim);
  text-shadow: 0 1px 8px rgba(10,11,13,0.55);
}

.headline{
  margin: 0;
  font-size: clamp(2.1rem, 4.8vw, 3.8rem);
  font-weight: 600;
  line-height: 1.16;
  letter-spacing: 0.005em;
  color: var(--accent);
  text-shadow: 0 1px 8px rgba(10,11,13,0.4);
}

.headline__small{
  display: inline-block;
}

.rule{
  display: block;
  width: 64px;
  height: 1px;
  margin: clamp(20px, 3.4vw, 30px) 0 clamp(18px, 3vw, 26px);
  background: var(--accent);
}

.subhead{
  margin: 0 0 16px;
  font-size: clamp(1.05rem, 1.7vw, 1.35rem);
  font-weight: 300;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cream);
  text-shadow: 0 1px 8px rgba(10,11,13,0.55);
}
.subhead strong{
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.16em;
}

.body-copy{
  max-width: 46ch;
  margin: 0 0 clamp(24px, 4vw, 34px);
  font-size: clamp(0.95rem, 1.05vw, 1.05rem);
  font-weight: 300;
  line-height: 1.7;
  color: var(--cream-dim);
  text-shadow: 0 1px 8px rgba(10,11,13,0.55);
}

.meta-pill{
  display: block;
  width: fit-content;
  margin: 0 0 clamp(28px, 4.6vw, 40px);
  padding: clamp(14px, 1.8vw, 18px) clamp(20px, 2.4vw, 26px);
  background: rgba(14,16,19,0.45);
  border: 1px solid var(--hairline);
  border-radius: 0px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.meta-list{
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.meta-list li{
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.92rem;
  font-weight: 300;
  letter-spacing: 0.06em;
  color: var(--cream);
}
.meta-icon{
  width: 19px;
  height: 19px;
  flex: none;
  color: var(--accent);
}

/* ---- register CTA ---- */
.btn-register{
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 15px 30px;
  border: 1px solid var(--accent);
  background: transparent;
  color: var(--cream);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.35s ease, color 0.35s ease, box-shadow 0.35s ease;
}
.btn-register svg{
  width: 17px;
  height: 17px;
  transition: transform 0.35s ease;
}
.btn-register:hover,
.btn-register:focus-visible{
  background: var(--accent);
  color: var(--ink);
  box-shadow: 0 8px 30px -6px rgba(255,255,255,0.4);
}
.btn-register:hover svg{ transform: translateX(4px); }

/* ==========================================================================
   Modal / Registration form
   ========================================================================== */

.modal-content{
  background: var(--ink-soft);
  border: 1px solid var(--accent-dim);
  border-radius: 2px;
  color: var(--cream);
  padding: clamp(30px, 5vw, 48px) clamp(24px, 5vw, 44px) clamp(28px, 4vw, 36px);
  position: relative;
  box-shadow: 0 30px 80px -20px rgba(0,0,0,0.6);
}

.btn-close-custom{
  position: absolute;
  top: 18px;
  right: 18px;
  width: 34px;
  height: 34px;
  border: 1px solid var(--hairline);
  background: transparent;
  color: var(--cream-dim);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color 0.25s ease, color 0.25s ease;
}
.btn-close-custom svg{ width: 14px; height: 14px; }
.btn-close-custom:hover{ border-color: var(--accent); color: var(--accent); }

.modal-header-custom{
  text-align: center;
  margin-bottom: clamp(24px, 4vw, 32px);
}
.modal-mark{
  height: 30px;
  width: auto;
  margin: 0 auto 14px;
}
.modal-eyebrow{
  margin: 0 0 8px;
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--accent);
}
.modal-title-custom{
  margin: 0 0 8px;
  font-size: clamp(1.5rem, 3vw, 1.9rem);
  font-weight: 600;
  color: var(--cream);
}
.modal-sub{
  margin: 0;
  font-size: 0.86rem;
  font-weight: 300;
  letter-spacing: 0.03em;
  color: var(--cream-faint);
}

.register-form{
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.row-group{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 479.98px){
  .row-group{ grid-template-columns: 1fr; }
}

.form-floating-group{
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.form-floating-group > label{
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cream-faint);
}

.form-control-custom{
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--hairline);
  color: var(--cream);
  font-family: var(--font);
  font-size: 0.98rem;
  font-weight: 300;
  padding: 8px 2px;
  transition: border-color 0.25s ease;
}
.form-control-custom::placeholder{ color: var(--cream-faint); font-weight: 300; }
.form-control-custom:focus{
  outline: none;
  border-bottom-color: var(--accent);
}

/* segmented "coming as" control */
.segmented{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.segmented__input{
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.segmented__label{
  display: block;
  text-align: center;
  padding: 10px 8px;
  border: 1px solid var(--hairline);
  color: var(--cream-dim);
  font-size: 0.78rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color 0.25s ease, color 0.25s ease, background 0.25s ease;
}
.segmented__input:checked + .segmented__label{
  border-color: var(--accent);
  color: var(--ink);
  background: var(--accent);
}
.segmented__input:focus-visible + .segmented__label{
  outline: 1.5px solid var(--accent-hover);
  outline-offset: 2px;
}

/* broker-only fields */
.broker-fields{
  display: none;
  flex-direction: column;
  gap: 16px;
  padding-top: 6px;
  border-top: 1px dashed var(--hairline);
  margin-top: 2px;
}
.broker-fields.is-visible{ display: flex; }
.broker-fields__note{
  margin: 4px 0 -4px;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}
.broker-fields__note span{
  color: var(--cream-faint);
  font-weight: 300;
  letter-spacing: 0.02em;
  text-transform: none;
}

.btn-submit{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 6px;
  padding: 15px 20px;
  border: none;
  background: var(--accent);
  color: var(--ink);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
}
.btn-submit svg{ width: 17px; height: 17px; }
.btn-submit:hover{ background: var(--accent-hover); }
.btn-submit:active{ transform: scale(0.99); }
.btn-submit:disabled{ opacity: 0.6; cursor: not-allowed; transform: none; }

.form-alert{
  padding: 12px 14px;
  border: 1px solid var(--hairline);
  border-left: 3px solid var(--accent);
  font-size: 0.82rem;
  font-weight: 300;
  line-height: 1.5;
  color: var(--cream);
}
.form-alert--error{
  border-left-color: #e07a6b;
  color: #f2d3cd;
}
.form-alert--success{
  border-left-color: #9fd6a3;
  color: #dcefdd;
}

.form-footnote{
  margin: 2px 0 0;
  font-size: 0.74rem;
  font-weight: 300;
  line-height: 1.6;
  text-align: center;
  color: var(--cream-faint);
}

/* modal backdrop tuning */
.modal-backdrop.show{ opacity: 0.75; }

/* ==========================================================================
   Responsive adjustments
   ========================================================================== */

@media (max-width: 767.98px){
  .brandmark{ gap: 12px; }
  .hero__content{ align-items: flex-end; }
  .body-copy{ max-width: 100%; }
  /* Portrait phones/small tablets crop much narrower than the image's aspect
     ratio; nudge right to keep the pool + lounge deck in frame instead of
     just the glass facade. */
  .hero__img{ object-position: 24% 55%; }
}

/* Wide desktop / large monitors crop much wider than the image's aspect
   ratio, which otherwise pulls the roadway into view on the right; pull
   the focal point back toward the building + pool. */
@media (min-width: 1200px){
  .hero__img{ object-position: 10% 50%; }
}

@media (max-width: 575.98px){
  .brandmark{ flex-wrap: wrap; justify-content: flex-start; }
  .brandmark__cv-name{ font-size: 12px; }
  .btn-register{ width: 100%; justify-content: center; }
}
