/* ===== 현장 컬러: 자료의 브랜드 색으로 바꾼다 ===== */
:root {
  --main: #8c1d2c;        /* 힐스테이트 버건디 (로고) */
  --point: #b8935a;       /* 골드 */
  --text: #222;
  --muted: #666;
  --line: #e6e0d6;
  --bg-alt: #f4efe6;      /* 프리미엄 자료 배경 베이지 */
  --header-h: 120px;      /* JS가 실제 헤더 높이로 갱신 */
  --inner: 1200px;
  --figure-max: 1100px;   /* 배치도·커뮤니티 등 큰 이미지 최대 폭 */
  --plan-max: 860px;      /* 평면도 최대 폭 (흐려지지 않게) */
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Pretendard Variable", Pretendard, -apple-system, "Malgun Gothic", sans-serif;
  color: var(--text);
  background: #fff;
  line-height: 1.6;
  word-break: keep-all;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
table { border-collapse: collapse; }

.inner { max-width: var(--inner); margin: 0 auto; padding: 0 20px; }
.inner.narrow { max-width: 560px; }

/* ===== 헤더: 로고 상단 중앙 + 메뉴 아래 ===== */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  background: rgba(255,255,255,.97);
  box-shadow: 0 1px 0 var(--line);
}
.header-top {
  position: relative;
  display: flex; justify-content: center; align-items: center;
  height: 68px; padding: 0 20px;
}
.logo img { height: 40px; width: auto; }
.header-call {
  position: absolute; right: 20px; top: 50%; transform: translateY(-50%);
  font-weight: 700; color: var(--main); font-size: 18px;
}
.gnb { border-top: 1px solid var(--line); }
.gnb ul {
  list-style: none; margin: 0 auto; padding: 0 12px;
  display: flex; justify-content: center; gap: 4px;
  max-width: var(--inner);
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.gnb ul::-webkit-scrollbar { display: none; }
.gnb li { flex: 0 0 auto; }
.gnb a {
  position: relative; display: block;
  padding: 14px 18px; font-size: 16px; font-weight: 600; color: #444;
  white-space: nowrap; transition: color .2s;
}
/* 밑줄: 전체 너비 유지 + scaleX → hover 해제 시 점이 남지 않음 */
.gnb a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0;
  height: 3px; background: var(--main);
  transform: scaleX(0); transform-origin: center;
  transition: transform .25s ease;
}
.gnb a:hover, .gnb a.is-active { color: var(--main); }
.gnb a:hover::after, .gnb a.is-active::after { transform: scaleX(1); }

/* 고정 헤더 아래로 섹션 제목이 오도록 (실측 높이) */
main { padding-top: var(--header-h); }
section[id], #top { scroll-margin-top: var(--header-h); }

/* ===== 메인 ===== */
.hero { background: #000; }
.hero-img { width: 100%; max-width: 1920px; margin: 0 auto; }

/* ===== 섹션 공통 ===== */
.section { padding: 56px 0 72px; }
.section.alt { background: var(--bg-alt); }
.sec-title {
  margin: 0 0 28px; text-align: center;
  font-size: 32px; font-weight: 800; color: var(--main); letter-spacing: -.02em;
}
.sec-desc { margin: -12px 0 28px; text-align: center; color: var(--muted); }

/* 표 */
.info-table { width: 100%; max-width: 900px; margin: 0 auto; border-top: 2px solid var(--main); }
.info-table th, .info-table td { padding: 14px 18px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.info-table th { width: 160px; background: #fafafa; font-weight: 700; color: var(--main); }

/* 이미지: 원본 비율 유지, 읽을 수 있는 폭 */
.figure { margin: 0 auto; }
.figure.wide { max-width: var(--figure-max); }
.figure.plan { max-width: var(--plan-max); }
.figure img { width: 100%; height: auto; margin: 0 auto; }
.figure figcaption { margin-top: 10px; text-align: center; font-size: 14px; color: var(--muted); }
.figure + .figure { margin-top: 28px; }

/* 카드 */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; }
.card { background: #fff; border-radius: 14px; overflow: hidden; box-shadow: 0 4px 18px rgba(0,0,0,.06); }
.card-img { border-radius: 14px 14px 0 0; overflow: hidden; }
.card-img img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.card h3 { margin: 18px 20px 6px; font-size: 19px; color: var(--main); }
.card p { margin: 0 20px 22px; color: var(--muted); font-size: 15px; }

/* 탭: 중앙 정렬, 선택 상태 명확 */
.tab-list { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 0 0 26px; }
.tab-btn {
  appearance: none; border: 1px solid var(--main); background: #fff; color: var(--main);
  padding: 10px 22px; border-radius: 999px; font: inherit; font-weight: 700; font-size: 15px;
  cursor: pointer; transition: background .2s, color .2s;
}
.tab-btn:hover { background: rgba(140,29,44,.07); }
.tab-btn.is-active { background: var(--main); color: #fff; }
.tabs.sub .tab-list { margin-bottom: 20px; }
.tabs.sub .tab-btn { border-radius: 8px; padding: 7px 16px; font-size: 14px; border-color: var(--point); color: var(--point); }
.tabs.sub .tab-btn.is-active { background: var(--point); color: #fff; }
.tab-panel { display: none; }
.tab-panel.is-active { display: block; }

/* ===== 관심고객 폼 ===== */
.register { background: var(--bg-alt); }
.reg-form { display: flex; flex-direction: column; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field span { font-weight: 700; font-size: 15px; }
.field input, .field textarea {
  width: 100%; padding: 14px 16px; font: inherit; font-size: 16px;
  border: 1px solid #ccc; border-radius: 10px; background: #fff;
}
.field input:focus, .field textarea:focus { outline: 2px solid var(--main); outline-offset: -1px; border-color: transparent; }
.agree { font-size: 14px; }
.agree-check { display: flex; align-items: flex-start; gap: 8px; cursor: pointer; }
.agree-check input { width: 18px; height: 18px; margin: 2px 0 0; flex: none; }
.agree-detail { margin-top: 6px; color: var(--muted); }
.agree-detail summary { cursor: pointer; font-size: 13px; }
.agree-detail p { margin: 8px 0 0; padding: 12px; background: #fff; border-radius: 8px; font-size: 13px; }
.btn-submit {
  width: 100%; padding: 16px; border: 0; border-radius: 10px;
  background: var(--main); color: #fff; font: inherit; font-size: 17px; font-weight: 800; cursor: pointer;
}
.btn-submit:disabled { opacity: .6; cursor: wait; }
.form-msg { min-height: 1.4em; margin: 0; text-align: center; font-weight: 600; }
.form-msg.ok { color: #1a7f37; }
.form-msg.err { color: #c62828; }

/* ===== 푸터 ===== */
.site-footer { background: #1b1b1b; color: #aaa; padding: 40px 0 90px; text-align: center; font-size: 14px; }
.footer-logo { height: 34px; width: auto; margin: 0 auto 14px; filter: brightness(0) invert(1); opacity: .85; } /* 흰 사각 배경 금지 */
.footer-call { margin: 0 0 10px; color: #fff; font-size: 16px; font-weight: 700; }
.footer-biz { margin: 0 0 10px; }
.footer-biz span + span::before { content: "|"; margin: 0 10px; color: #555; }
.footer-note { margin: 0; font-size: 12px; color: #777; }

/* 플로팅 전화 */
.float-call {
  position: fixed; right: 18px; bottom: 18px; z-index: 90;
  display: flex; align-items: center; gap: 8px;
  padding: 12px 18px; border-radius: 999px;
  background: var(--point); color: #fff; font-weight: 800;
  box-shadow: 0 6px 20px rgba(0,0,0,.2);
}

/* ===== 모바일 ===== */
@media (max-width: 768px) {
  .header-top { height: 56px; }
  .logo img { height: 30px; }
  .header-call { display: none; }
  .gnb ul { justify-content: flex-start; padding: 0 8px; }
  .gnb a { padding: 12px 12px; font-size: 15px; }
  .section { padding: 40px 0 52px; }
  .sec-title { font-size: 24px; margin-bottom: 20px; }
  .info-table th { width: 96px; padding: 12px; font-size: 14px; }
  .info-table td { padding: 12px; font-size: 14px; }
  .tab-btn { padding: 8px 16px; font-size: 14px; }
  .footer-biz span { display: block; }
  .footer-biz span + span::before { content: none; }
  .float-call span { display: none; }
  .float-call { padding: 14px; }
}
/* 메뉴가 화면보다 넓지 않으면 가운데 정렬 유지 (JS가 클래스 부여) */
.gnb ul.fits { justify-content: center; }

/* ================= 힐스테이트 양산 더스카이 ================= */
.logo img { height: 46px; }

/* 메인 */
.hero { position: relative; background: linear-gradient(#4f8fd6, #9cc6ef); overflow: hidden; }
.hero-img { max-width: 1200px; position: relative; z-index: 1; }
.hero::before { /* 큰 화면 양옆: 같은 사진을 흐리게 */
  content: ""; position: absolute; inset: -40px;
  background: url(../assets/main.jpg) center / cover no-repeat;
  filter: blur(28px) saturate(1.05); opacity: .9;
}
.hero-copy { z-index: 2; }
.hero-copy {
  position: absolute; left: 50%; top: 9%; transform: translateX(-50%);
  width: min(1200px, 100%); padding: 0 56px; color: #fff;
  text-shadow: 0 2px 14px rgba(0,0,0,.28);
}
.hero-kicker { margin: 0 0 6px; font-size: 20px; font-weight: 600; letter-spacing: .02em; }
.hero-copy h1 { margin: 0; font-size: 46px; font-weight: 800; letter-spacing: -.03em; line-height: 1.2; }
.hero-sub { margin: 10px 0 22px; font-size: 17px; opacity: .95; }
.hero-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-primary, .btn-line {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 150px; padding: 13px 22px; border-radius: 999px; font-weight: 800; text-shadow: none;
}
.btn-primary { background: var(--main); color: #fff; box-shadow: 0 6px 18px rgba(140,29,44,.35); }
.btn-line { background: rgba(255,255,255,.92); color: var(--main); }

/* 섹션 머리 */
.sec-head { text-align: center; margin-bottom: 30px; }
.sec-head > span { display: block; color: var(--point); font-size: 13px; font-weight: 800; letter-spacing: .22em; margin-bottom: 6px; }
.sec-head .sec-title { margin-bottom: 0; }
.sec-head .sec-desc { margin: 10px 0 0; }
.sec-title::after { content: ""; display: block; width: 34px; height: 3px; margin: 14px auto 0; background: var(--main); }

/* 사업안내 */
.biz-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: center; }
.biz-img { margin: 0; border-radius: 14px; overflow: hidden; box-shadow: 0 10px 30px rgba(0,0,0,.08); }
.biz-img img { width: 100%; }
.biz-grid .info-table { max-width: none; }
.info-table th { width: 130px; background: #faf7f2; }
.info-table .sub { color: #555; font-size: 15px; }

/* 프리미엄 카드 */
.premium-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.pcard {
  position: relative; background: #fff; padding: 30px 26px 30px; border-radius: 4px;
  border: 1px solid var(--line); border-bottom: 5px solid #eadfcd;
  transition: transform .25s, box-shadow .25s;
}
.pcard:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(0,0,0,.07); }
.pcard b { display: block; font-size: 40px; font-weight: 300; color: var(--main); line-height: 1; }
.pcard em { display: block; margin: 12px 0 10px; font-style: normal; font-size: 12px; font-weight: 800; color: var(--main); letter-spacing: .05em; }
.pcard h3 { margin: 0 0 12px; font-size: 20px; font-weight: 700; letter-spacing: -.02em; }
.pcard p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.65; }

/* 확대 보기 */
.zoomable a { display: block; cursor: zoom-in; }
.zoom-hint { display: none; margin: 14px 0 0; text-align: center; font-size: 13px; color: var(--muted); }

/* 폼 하단 전화 */
.reg-call { display: block; margin-top: 18px; text-align: center; color: var(--main); font-size: 16px; }
.reg-call strong { font-size: 22px; margin-left: 6px; }

/* 푸터 로고: 투명 PNG를 흰색으로 */
.footer-logo { height: 40px; }

@media (max-width: 1024px) {
  .premium-grid { grid-template-columns: repeat(2, 1fr); }
  .biz-grid { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .logo img { height: 34px; }
  .hero { background: #fff; }
  .hero::before { display: none; }
  .hero-copy {
    position: static; transform: none; width: auto; padding: 22px 20px 26px;
    color: var(--text); text-shadow: none; text-align: center;
    background: #fff;
  }
  .hero-kicker { font-size: 15px; color: var(--main); }
  .hero-copy h1 { font-size: 27px; }
  .hero-sub { font-size: 14px; color: var(--muted); margin-bottom: 16px; }
  .hero-btns { justify-content: center; }
  .btn-primary, .btn-line { min-width: 0; flex: 1; padding: 12px 10px; }
  .btn-line { border: 1px solid var(--main); }
  .premium-grid { grid-template-columns: 1fr; gap: 14px; }
  .pcard { padding: 24px 20px; }
  .pcard b { font-size: 32px; }
  .pcard h3 { font-size: 18px; }
  .info-table th { width: 92px; }
  .info-table .sub { font-size: 13px; }
  .zoom-hint { display: block; }
  .tab-list { gap: 6px; }
}
