/* ============================================================
   Salina Regional Homes – Main Stylesheet
   ============================================================ */

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

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: 'Open Sans', 'Helvetica Neue', Arial, sans-serif;
  color: #333;
  background: #fff;
  line-height: 1.6;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
svg { max-width: 100%; overflow: hidden; }
ul { list-style: none; }

/* ----- Utility ----- */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.text-center { text-align: center; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

/* ============================================================
   TOP BAR
   ============================================================ */
#topbar {
  background: #12243d;
  color: #fff;
  font-size: 0.8rem;
  padding: 0.4rem 1.5rem;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 1.5rem;
}

#topbar a {
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  transition: opacity 0.2s;
}
#topbar a:hover { opacity: 0.8; }

#topbar .icon {
  width: 16px;
  height: 16px;
  fill: #fff;
  display: inline-block;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
#navbar {
  background: rgba(18, 36, 61, 0.92);
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  height: 58px;
  backdrop-filter: blur(4px);
}

#navbar .nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

#navbar .nav-links a,
#navbar .nav-links .dropdown > a {
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  padding: 0.5rem 1rem;
  text-transform: uppercase;
  border-radius: 3px;
  transition: background 0.2s;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

#navbar .nav-links a:hover,
#navbar .nav-links .dropdown:hover > a { background: rgba(255,255,255,0.12); }

/* Dropdown */
.dropdown { position: relative; }

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #12243d;
  min-width: 200px;
  border-top: 2px solid #c8a84b;
  z-index: 999;
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}

.dropdown:hover .dropdown-menu { display: block; }

.dropdown-menu a {
  display: block !important;
  padding: 0.7rem 1.2rem !important;
  font-size: 0.82rem !important;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.dropdown-menu a:hover { background: rgba(255,255,255,0.1) !important; }

.caret {
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid #fff;
  display: inline-block;
}

/* Mobile burger */
.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 0.5rem;
}
.burger span { display: block; width: 24px; height: 2px; background: #fff; border-radius: 2px; }

/* ============================================================
   HERO
   ============================================================ */
#hero {
  position: relative;
  height: 280px !important;
  min-height: unset !important;
  max-height: 280px !important;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  overflow: hidden;
  background: #12243d;
}

#hero .hero-bg {
  object-fit: cover;
  object-position: center 15% !important;
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 0;
}

#hero .hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: #fff;
  padding: 30px 48px 0;
  display: flex;
  width: 90%;
  max-width: 960px;
  margin: 0 auto;
  flex-direction: column;
  align-items: center;
}
#hero .site-logo {
  margin-bottom: 0 !important;
  line-height: 1;
}
#hero .hero-content h1 {
  margin-top: 2px !important;
  margin-bottom: 10px !important;
}


#hero h1 {
  font-size: 2.6rem;
  font-weight: 700;
  text-shadow: 0 2px 8px rgba(0,0,0,0.6);
  margin-top: 2px !important;
  margin-bottom: 10px !important;
  letter-spacing: 0.02em;
}


/* Hide hero h1 - logo only */
#hero .hero-content h1 { display: none !important; }
/* ----- Search Bar ----- */
#search-bar {
  background: #fff;
  border-radius: 3px;
  display: flex;
  align-items: center;
  max-width: 870px;
  margin: 0 auto 0.75rem;
  overflow: visible;
  box-shadow: 0 4px 20px rgba(0,0,0,0.35);
}

#search-bar input[type="text"] {
  flex: 1;
  border: none;
  outline: none;
  padding: 0.9rem 1rem;
  font-size: 0.9rem;
  color: #555;
  min-width: 0;
}

#search-bar select {
  border: none;
  border-left: 1px solid #ddd;
  outline: none;
  padding: 0.9rem 0.75rem;
  font-size: 0.85rem;
  color: #555;
  background: #fff;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23999'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  padding-right: 2rem;
}

#search-bar .search-btn {
  background: #12243d;
  color: #fff;
  border: none;
  padding: 0 1.8rem;
  height: 100%;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  text-transform: uppercase;
  transition: background 0.2s;
  white-space: nowrap;
  align-self: stretch;
  display: flex;
  align-items: center;
}
#search-bar .search-btn:hover { background: #1e3a5f; }

.more-options-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #12243d;
  color: #fff;
  border: none;
  padding: 0.55rem 1.4rem;
  border-radius: 3px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  letter-spacing: 0.04em;
  transition: background 0.2s;
}
.more-options-btn:hover { background: #1e3a5f; }
.more-options-btn svg { width: 14px; height: 14px; fill: #fff; }

/* ============================================================
   FEATURE SECTIONS  (image + text overlay)
   ============================================================ */
.feature-section {
  position: relative;
  height: 480px;
  overflow: hidden;
}

.feature-section img.bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.feature-section .overlay {
  position: absolute;
  inset: 0;
  top: 0; bottom: 0;
  width: 40%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: #fff;
  padding: 2.5rem 3rem;
}

.feature-section .overlay.right {
  left: auto;
  right: 0;
  background: linear-gradient(to left, rgba(18,36,61,0.9), rgba(18,36,61,0.02));
  text-align: right;
  align-items: flex-end;
}

.feature-section .overlay.left {
  left: 0;
  background: linear-gradient(to right, rgba(18,36,61,0.9), rgba(18,36,61,0.02));
  text-align: left;
  align-items: flex-start;
}

.feature-section h2 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.feature-section p {
  font-size: 1rem;
  margin-bottom: 1.5rem;
  line-height: 1.7;
  opacity: 0.92;
}

.btn {
  display: inline-block;
  padding: 0.65rem 1.6rem;
  border-radius: 3px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: background 0.2s, color 0.2s;
  cursor: pointer;
  border: 2px solid transparent;
}

.btn-outline-light {
  background: transparent;
  color: #fff;
  border-color: #fff;
}
.btn-outline-light:hover { background: #fff; color: #12243d; }

.btn-primary {
  background: #12243d;
  color: #fff;
  border-color: #12243d;
}
.btn-primary:hover { background: #1e3a5f; border-color: #1e3a5f; }

/* ============================================================
   CONTENT SECTION  (centered text block)
   ============================================================ */
.content-section {
  padding: 4.5rem 1.5rem;
  text-align: center;
}

.content-section .eyebrow {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #666;
  margin-bottom: 1.2rem;
}

.content-section .eyebrow::after {
  content: "";
  display: block;
  width: 60px;
  height: 1px;
  background: #aaa;
  margin: 0.9rem auto 0;
}

.content-section h2 {
  font-size: 2.4rem;
  font-weight: 700;
  margin-bottom: 1.1rem;
  color: #12243d;
}

.content-section p {
  font-size: 1.05rem;
  max-width: 720px;
  margin: 0 auto 2rem;
  color: #555;
}

/* ============================================================
   PROPERTY CATEGORY COUNTS
   ============================================================ */
#category-counts {
  background: #f5f7fa;
  border-top: 1px solid #e4e8ef;
}

.cat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.cat-item {
  padding: 2.5rem 1.5rem;
  text-align: center;
  border-right: 1px solid #e4e8ef;
  transition: background 0.2s;
}
.cat-item:last-child { border-right: none; }
.cat-item:hover { background: #eaecf5; }

.cat-item a { display: block; }

.cat-count {
  font-size: 2.8rem;
  font-weight: 700;
  color: #12243d;
  line-height: 1;
  margin-bottom: 0.4rem;
}

.cat-label {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #555;
  margin-bottom: 0.5rem;
}

.cat-link {
  font-size: 0.78rem;
  color: #c8a84b;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ============================================================
   FOOTER
   ============================================================ */
footer {
  background: #0d1c30;
  color: #b0bcc8;
  padding: 3.5rem 1.5rem 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2.5rem;
  max-width: 1200px;
  margin: 0 auto 2.5rem;
}

footer h4 {
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.footer-brand .brand-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.5rem;
}

footer p { font-size: 0.85rem; line-height: 1.8; }

footer ul li { margin-bottom: 0.5rem; }
footer ul li a { font-size: 0.85rem; color: #b0bcc8; transition: color 0.2s; }
footer ul li a:hover { color: #fff; }

.footer-social { display: flex; gap: 0.75rem; margin-top: 1rem; }
.footer-social a {
  width: 34px; height: 34px;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s;
}
.footer-social a:hover { background: rgba(255,255,255,0.22); }
.footer-social svg { width: 16px; height: 16px; fill: #fff; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 1.2rem;
  text-align: center;
  font-size: 0.78rem;
  max-width: 1200px;
  margin: 0 auto;
}

/* ============================================================
   LOGO (SVG text-based)
   ============================================================ */
.site-logo {
  display: inline-block !important;
  margin-bottom: 10px !important;
}

.logo-icon {
  display: flex;
  gap: 4px;
  margin-bottom: 4px;
}

.logo-bar {
  width: 8px;
  border-radius: 2px 2px 0 0;
}

.logo-bar:nth-child(1) { height: 28px; background: #c8a84b; }
.logo-bar:nth-child(2) { height: 36px; background: #1e5fa8; }
.logo-bar:nth-child(3) { height: 44px; background: #c8313a; }
.logo-bar:nth-child(4) { height: 36px; background: #1e5fa8; }
.logo-bar:nth-child(5) { height: 28px; background: #c8a84b; }

.logo-text-top {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #fff;
  line-height: 1;
}

.logo-text-sub {
  font-size: 0.6rem;
  letter-spacing: 0.22em;
  color: rgba(255,255,255,0.85);
  line-height: 1;
  margin-top: 1px;
}

.logo-text-realtors {
  font-size: 0.55rem;
  letter-spacing: 0.16em;
  color: rgba(255,255,255,0.7);
}

/* ============================================================
   PAGE HERO  (for inner pages)
   ============================================================ */
.page-hero {
  background: #12243d;
  color: #fff;
  text-align: center;
  padding: 4rem 1.5rem 3rem;
}

.page-hero h1 {
  font-size: 2.2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.page-hero p { font-size: 1.05rem; opacity: 0.85; max-width: 600px; margin: 0 auto; }

/* ============================================================
   CONTACT PAGE
   ============================================================ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  max-width: 1000px;
  margin: 3rem auto;
  padding: 0 1.5rem;
}

.contact-form label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
  color: #444;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  padding: 0.7rem 0.9rem;
  border: 1px solid #ccc;
  border-radius: 3px;
  font-size: 0.9rem;
  margin-bottom: 1.1rem;
  font-family: inherit;
  color: #333;
  outline: none;
  transition: border-color 0.2s;
}

.contact-form input:focus,
.contact-form textarea:focus { border-color: #12243d; }
.contact-form textarea { resize: vertical; min-height: 130px; }

.contact-info h3 { font-size: 1.3rem; color: #12243d; margin-bottom: 1rem; }
.contact-info p { font-size: 0.9rem; color: #555; margin-bottom: 0.6rem; line-height: 1.7; }
.contact-info strong { color: #333; }

/* ============================================================
   AGENTS PAGE
   ============================================================ */
.agents-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 1100px;
  margin: 3rem auto;
  padding: 0 1.5rem;
}

.agent-card {
  border: 1px solid #e4e8ef;
  border-radius: 6px;
  overflow: hidden;
  text-align: center;
  transition: box-shadow 0.2s;
}
.agent-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,0.1); }

.agent-card .agent-photo {
  width: 100%;
  height: 240px;
  object-fit: cover;
  background: #dde3ec;
}

.agent-card .agent-info { padding: 1.2rem; }
.agent-card h3 { font-size: 1.05rem; color: #12243d; margin-bottom: 0.3rem; }
.agent-card .title { font-size: 0.8rem; color: #c8a84b; font-weight: 600; letter-spacing: 0.06em; margin-bottom: 0.7rem; }
.agent-card p { font-size: 0.85rem; color: #666; }

/* ============================================================
   SELL PAGE
   ============================================================ */
.sell-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 1000px;
  margin: 3rem auto;
  padding: 0 1.5rem;
}

.step-card {
  text-align: center;
  padding: 2rem 1.5rem;
  border: 1px solid #e4e8ef;
  border-radius: 6px;
}

.step-number {
  width: 52px; height: 52px;
  background: #12243d;
  color: #fff;
  font-size: 1.3rem;
  font-weight: 700;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1rem;
}

.step-card h3 { font-size: 1.05rem; color: #12243d; margin-bottom: 0.6rem; }
.step-card p { font-size: 0.88rem; color: #666; line-height: 1.7; }

/* ============================================================
   SEARCH / IDX PLACEHOLDER
   ============================================================ */
.idx-placeholder {
  max-width: 960px;
  margin: 3rem auto;
  padding: 3rem 2rem;
  border: 2px dashed #c4cdd8;
  border-radius: 8px;
  text-align: center;
  background: #f8f9fb;
}

.idx-placeholder h2 { color: #12243d; font-size: 1.5rem; margin-bottom: 0.7rem; }
.idx-placeholder p { color: #666; font-size: 0.95rem; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .cat-item:nth-child(2) { border-right: none; }
  .cat-item:nth-child(3) { border-top: 1px solid #e4e8ef; }
  .agents-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  #hero { height: 200px; }
  #hero h1 { font-size: 1.8rem; }

  #search-bar {
    flex-wrap: wrap;
    border-radius: 3px;
  }
  #search-bar input[type="text"] { width: 100%; border-bottom: 1px solid #ddd; }
  #search-bar select { border-left: none; border-bottom: 1px solid #ddd; flex: 1; }
  #search-bar .search-btn { width: 100%; justify-content: center; padding: 0.9rem; }

  .feature-section { height: auto; min-height: 350px; }
  .feature-section .overlay {
    width: 100% !important;
    background: rgba(18,36,61,0.82) !important;
    position: relative !important;
    padding: 2rem 1.5rem;
    text-align: center !important;
    align-items: center !important;
  }
  .feature-section img.bg { position: absolute; opacity: 0.25; }

  .content-section h2 { font-size: 1.8rem; }

  .footer-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }

  .contact-grid { grid-template-columns: 1fr; }
  .sell-steps { grid-template-columns: 1fr; }
  .agents-grid { grid-template-columns: 1fr; }

  .burger { display: flex; }
  #navbar .nav-links { display: none; }
  #navbar .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 58px; left: 0; right: 0;
    background: #12243d;
    padding: 1rem 0;
    gap: 0;
  }
  .dropdown-menu { position: static; box-shadow: none; border-top: none; padding-left: 1rem; }
}


/* === Hero tight spacing overrides === */
#hero .logo-img {
  max-height: 180px !important;
  width: auto !important;
  max-width: 100% !important;
}
#hero .hero-content {
  gap: 0 !important;
}
#hero .site-logo {
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1 !important;
}
#hero .site-logo img {
  display: block !important;
  margin: 0 !important;
}
#hero .hero-content h1 {
  margin: 4px 0 10px !important;
  padding: 0 !important;
}


/* === Mobile hero & logo overrides === */
@media (max-width: 768px) {
  #hero {
    height: 200px !important;
    min-height: unset !important;
    max-height: 200px !important;
  }
  #hero .logo-img {
    max-height: 175px !important;
    width: auto !important;
  }
  #hero .hero-content {
    padding: 16px 16px 20px !important;
    width: 95% !important;
  }
  #hero h1 {
    font-size: 1.6rem !important;
  }
  #search-bar {
    flex-direction: column !important;
    width: 100% !important;
  }
  #search-bar input[type="text"] {
    width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }
  #search-bar select {
    width: 48% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    flex: none !important;
  }
  #search-bar .search-btn {
    width: 100% !important;
  }
}

@media (max-width: 480px) {
  #hero {
    height: 160px !important;
    min-height: unset !important;
    max-height: 160px !important;
  }
  #hero .logo-img {
    max-height: 138px !important;
  }
  #hero h1 {
    font-size: 1.4rem !important;
  }
  #hero .hero-content {
    padding: 12px 12px 16px !important;
  }
}
