/* 昭揚X李天鐸案｜樣式
   重建依據：舊官網 https://k2.h2.com.tw/（2026-11-24 量測）。每一段的寬度、間距、斷點都照舊站的數字，
   目的是「看起來一模一樣」，所以這裡的百分比與像素不要順手改成整齊的數字。
   斷點（和舊站相同）：481、769、1025、1441；浮動按鈕另外在 680 與 480 變化。
   整頁除了表單與按鈕，內容都是圖（文字圖與照片），所以這裡主要是在排圖的位置。 */

:root {
  /* 顏色（全部取自舊站） */
  --ink: #212529;
  --field-ink: #333;
  --white: #fff;
  --navy: #1f466b;         /* 表單的字、框線、送出按鈕 */
  --accent: #da4423;       /* 滑過時的橘紅：送出按鈕、條款連結、輪播箭頭 */
  --error: #900;           /* 表單錯誤訊息（舊站的顏色） */
  --sc: #f7917b;           /* 浮動按鈕（電腦） */
  --sc-ink: #21466c;
  --sc-bar: rgba(218, 68, 35, .65); /* 浮動按鈕（手機底部那一排） */
  --flag: #961c1c;         /* 預覽標示 */
  /* 字體照舊站：頁面是系統字，表單那一段是微軟正黑體（其餘文字都是圖） */
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
  --font-form: "微軟正黑體", "Arial", sans-serif;
  --ease: ease-in-out;
}

*, *::before, *::after { box-sizing: border-box; }
html { overflow-x: clip; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; overflow-x: clip; font: 400 16px/1.5 var(--font); color: var(--ink); background: var(--white); }
h1, h2, h3, p, ul { margin: 0; padding: 0; font-size: inherit; font-weight: inherit; }
ul { list-style: none; }
picture { display: block; }
/* 照線上：圖一律撐滿所在的框，框比圖的原始寬度大時會跟著放大（舊站沒有設上限） */
img { display: block; width: 100%; height: auto; }
button, input { margin: 0; font: inherit; }
/* 焦點框：白線外面再包一圈深藍，在白底與照片上都看得見（舊站把焦點框關掉了，這裡補回來） */
:focus-visible { outline: 2px solid var(--white); outline-offset: 2px; box-shadow: 0 0 0 6px var(--navy); }

.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.only-pc { display: none !important; }

/* ── 01 主視覺：背景圖墊在最底下（不佔位置），標誌與兩張文字圖照順序往下排。
      這一段的高度由上內距＋標誌＋文字圖決定，下面那一大段留白是下外距（都是寬度的百分比） ── */
.hero { position: relative; margin: 0 0 33%; padding: 22% 0 0; }
.hero__bg { position: absolute; top: 0; right: 0; z-index: -1; width: 100%; }
.hero__logo { width: 40%; margin: 0 30%; }
.hero__text { width: 70%; margin: 6% 15% 8%; }
.hero__name { width: 80%; margin: 0 10%; }
.hero__sub { width: 100%; margin: 10% 0 0; }

/* ── 02～04 三個圖文區塊：文字欄（blk__t）與圖片欄（blk__i）；手機由上往下，769 以上左右排並上下置中 ── */
.blk { display: flex; flex-wrap: wrap; align-items: center; }
.blk__t { width: 70%; margin: 0 15%; }
.blk__i { width: 100%; margin: 25px 0; }
.s1, .s2 { padding: 50px 0; overflow: hidden; }
/* 照線上：大圖上下各多 8px（舊站那兩層標題的預設外距），桌機只有下面 8px */
.s1__i { padding: 8px 0; }
.s2__i { position: relative; }
/* 疊在輪播左下角的那一行英文字；不攔手指與滑鼠，照片才拖得動 */
.s2__it { position: absolute; bottom: 5%; left: 2%; z-index: 3; width: 45%; pointer-events: none; }
.s3__i { width: 70%; margin: 25px 15%; }

/* ── 區塊之間的線條圖（第二條左右翻轉） ── */
.line { width: 90%; margin: 25px 10% 25px 0; }
.line--flip { margin: 25px 0 25px 10%; }
.line--flip img { transform: scaleX(-1); }

/* ── 輪播（左右箭頭、沒有圓點）。第三區那一個在 769 以上一次顯示兩張、沒有箭頭 ── */
.carousel { position: relative; width: 100%; }
.carousel__viewport { overflow: hidden; }
.carousel__track { display: flex; touch-action: pan-y; }
.carousel__slide { flex: 0 0 100%; min-width: 0; }
.carousel__track.is-dragging { cursor: grabbing; }
/* 程式沒有載入時：改成可以用手指左右滑的清單，內容一樣看得到；箭頭沒有作用，收起來 */
html:not(.js) .carousel__viewport { overflow-x: auto; scroll-snap-type: x mandatory; }
html:not(.js) .carousel__slide { scroll-snap-align: start; }
.carousel__nav { height: 0; }
html:not(.js) .carousel__nav { display: none; }
.carousel__arrow { position: absolute; top: 43%; z-index: 10; width: 14px; height: 30px; margin: 5px auto; padding: 0; color: var(--white); background: none; border: 0; opacity: .6; cursor: pointer; transition: color .25s var(--ease), opacity .25s var(--ease); }
.carousel__arrow::after { content: ""; position: absolute; inset: -8px -15px; } /* 看起來很細，可以點的範圍放大到 44px 見方 */
.carousel__arrow:hover { color: var(--accent); opacity: 1; }
.carousel__arrow--prev { left: 10px; }
.carousel__arrow--next { right: 10px; }
/* 箭頭的形狀照舊站：一個圓頭的角括號，寬放大 1.2 倍、高放大 2.8 倍（舊站用的是圖示字型，這裡自己畫） */
.chev { position: absolute; top: 8px; left: 0; display: block; width: .625em; height: 1em; font-size: 1.05em; fill: currentColor; transform: translateY(-.1em) scale(1.2, 2.8); }

/* ── 05 預約賞屋（表單）。照舊站：這一區是一個會換行的橫排，標題、說明、表單各佔一排 ── */
.contact { display: flex; flex-wrap: wrap; width: 90%; margin: 45px 5%; font-family: var(--font-form); }
.contact__title { width: 50%; margin: 0 25%; }
.contact__sub { width: 96%; margin: 18px 2% 22px; }
.form { width: 100%; }
.form__field { display: flex; flex-wrap: wrap; align-items: center; width: 100%; margin: 10px 0; }
.form__label { display: flex; flex-wrap: wrap; align-items: center; width: 100%; margin: 0 0 8px; font-size: 1.15em; font-weight: 700; letter-spacing: 1px; color: var(--navy); }
.form__label--plain { display: block; }
.form__label small { font-size: .65em; font-weight: 900; }
.form__input { width: 100%; padding: 3px 6px; font-size: 1.2em; color: #000; background: var(--white); border: 1px solid var(--navy); border-radius: 2px; }
.form__input[aria-invalid="true"] { color: var(--error); } /* 照舊站：沒填對時，框裡的字也變成暗紅 */
.form__rooms { display: flex; flex-wrap: wrap; justify-content: flex-start; align-items: flex-start; width: 100%; margin: 4px 0; }
.form__choice { display: flex; flex-wrap: wrap; align-items: center; margin: 0 25px 6px 0; font-size: 1.2em; color: var(--navy); cursor: pointer; }
.form__choice input { margin: 0 8px 0 0; }

.form__consent { display: flex; flex-wrap: wrap; align-items: center; width: 100%; margin: 25px 0 0; font-size: 1em; font-weight: 700; letter-spacing: 1px; color: var(--navy); }
.form__agree { display: flex; flex-wrap: wrap; align-items: center; }
.form__consent label { display: flex; align-items: center; }
.form__consent input { flex: none; width: 25px; height: 25px; margin: 0 8px 0 0; }
.form__consent a { display: flex; margin-left: 8px; font-weight: 700; color: var(--navy); text-decoration: underline; transition: color .25s var(--ease); }
.form__consent a:hover { color: var(--accent); text-decoration: none; }

/* 錯誤訊息：位置與顏色照舊站。姓名、電話的在輸入框下面另起一行；
   房型的接在選項後面（樣子和選項一樣）；同意條款的接在那一行後面，放不下才換行 */
.form__error { width: 100%; font-size: 1em; font-weight: 400; letter-spacing: 0; color: var(--error); }
.form__error:empty { display: none; }
.form__error--choice { width: auto; margin: 0 25px 6px 0; font-size: 1.2em; color: var(--navy); }
.form__error--consent { width: auto; font-weight: 700; letter-spacing: 1px; }

/* 人機驗證的位置（平常不顯示，高度是 0） */
.form__code { display: flex; justify-content: center; align-items: center; width: 100%; margin: 35px 0; }
.form__btn { position: relative; display: flex; justify-content: center; width: 100%; margin: 0; padding: 10px 0; overflow: hidden; font-size: 1em; font-weight: 700; line-height: 1.5; letter-spacing: 1px; color: var(--white); background: var(--navy); border: 0; border-radius: 2px; cursor: pointer; transition: background-color .25s var(--ease); }
.form__btn:hover { background: var(--accent); }
.form__btn:disabled { cursor: progress; }
/* 送出中：按鈕底下一條來回跑的細線，讓人知道有在處理 */
.form__btn.is-sending::after { content: ""; position: absolute; left: 0; bottom: 0; width: 40%; height: 2px; background: var(--white); animation: sending 1.1s var(--ease) infinite alternate; }
@keyframes sending { from { transform: translateX(-100%); } to { transform: translateX(250%); } }

.form-done { width: 100%; padding: 28px 20px; text-align: center; color: var(--navy); background: var(--white); border: 1px solid var(--navy); border-radius: 2px; }
.form-done strong { display: block; margin: 0 0 6px; font-size: 1.25em; letter-spacing: 1px; }
.form-done:focus { outline: none; }

/* ── 最下面那一行字。照線上是白字，在白底上看不見（見 index.html 的說明） ── */
.bottom { width: 90%; margin: 60px 5% 35px; font-size: .95em; font-weight: 700; letter-spacing: 1px; text-align: right; color: var(--white); }

/* ── 浮動聯絡按鈕 ── */
.shortcuts { position: fixed; right: 15px; bottom: 15px; z-index: 2000; width: 50px; }
.shortcuts__in { display: flex; flex-wrap: wrap; width: 100%; }
.shortcuts a { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; width: 50px; height: 50px; margin: 0 0 10px; font-size: 1.25em; font-weight: 700; color: var(--sc-ink); text-decoration: none; background: var(--sc); border: 2px solid var(--sc); border-radius: 50%; transition: color .25s var(--ease), background-color .25s var(--ease), border-color .25s var(--ease); }
.shortcuts a[hidden] { display: none; } /* 後台把這一顆刪掉時 */
.shortcuts a:hover { color: var(--white); background: var(--sc-ink); border-color: var(--sc-ink); }
.shortcuts a span { display: none; }
.ico { display: block; height: 1.25em; fill: currentColor; }
.ico--fb { width: .78em; }
.ico--pin { width: .94em; }
.ico--tel { width: 1.25em; }

/* ── 跳出視窗（個資保護條款）。尺寸與淡入淡出照舊站：白底、內距 24px、0.33 秒 ── */
.modal { --modal-fade: .33s; width: 548px; max-width: calc(100vw - 30px); max-height: calc(100vh - 88px); padding: 24px; overflow: auto; color: var(--ink); background: var(--white); border: 0; border-radius: 5px; box-shadow: 0 2px 15px #222; }
.modal[open] { animation: modal-in var(--modal-fade) cubic-bezier(.22, .61, .36, 1) both; }
.modal::backdrop { background: rgba(15, 15, 17, .87); }
.modal[open]::backdrop { animation: modal-in var(--modal-fade) cubic-bezier(.22, .61, .36, 1) both; }
.modal.is-closing, .modal.is-closing::backdrop { animation: modal-out var(--modal-fade) cubic-bezier(.55, .06, .68, .19) both; }
.modal__title { margin: 0 0 15px; padding: 15px 0; font-size: 1.35em; font-weight: 500; line-height: 1.2; letter-spacing: 1px; color: var(--field-ink); border-bottom: 1px solid #aaa; }
.modal__body { font-size: 1.15em; line-height: 1.35; }
.modal__close { position: absolute; top: 0; right: 0; z-index: 10; width: 44px; height: 44px; padding: 0; background: transparent; border: 0; cursor: pointer; }
.modal__close::after { content: "×"; position: absolute; top: 5px; right: 5px; width: 30px; height: 30px; font: 300 45px/30px Arial, "Helvetica Neue", Helvetica, sans-serif; text-align: center; color: #888; background: var(--white); border-radius: 50%; transition: background-color .2s; }
.modal__close:hover::after { color: #555; background: #eee; }
.modal__close:focus::after { outline: 1px dotted #888; } /* 舊站視窗一打開，焦點就在叉叉上，所以一開始就看得到這圈虛線 */
.modal__close:focus-visible { outline-color: var(--navy); outline-offset: -6px; box-shadow: none; }
@keyframes modal-in { from { opacity: 0; } }
@keyframes modal-out { to { opacity: 0; } }
@media (max-width: 769px) { .modal { width: 508px; } }
@media (max-width: 480px) { .modal { width: 348px; } .modal__title { font-size: 1.25em; } .modal__body { font-size: 1.05em; } }
@media (max-width: 360px) { .modal { width: 308px; } .modal__body { font-size: 1em; } }

/* ── 提示訊息 ── */
.toast { position: fixed; left: 50%; bottom: 70px; z-index: 3000; max-width: calc(100vw - 30px); padding: 10px 18px; font-size: .95em; color: var(--white); background: rgba(31, 70, 107, .95); border-radius: 4px; opacity: 0; pointer-events: none; transform: translate3d(-50%, 8px, 0); transition: opacity .25s ease, transform .25s ease; }
.toast.is-on { opacity: 1; transform: translate3d(-50%, 0, 0); }

/* ── 預覽標示（共用程式在預覽版加上的那一條） ── */
.preview-flag { position: fixed; top: 0; left: 50%; z-index: 4000; padding: 4px 14px; font-size: 12px; letter-spacing: 1px; color: var(--white); background: var(--flag); border-radius: 0 0 4px 4px; transform: translateX(-50%); pointer-events: none; }
/* 手機：改放右上角並縮小，不擋主視覺中間的字 */
@media (max-width: 768px) { .preview-flag { left: auto; right: 0; padding: 3px 8px; font-size: 11px; letter-spacing: 0; border-radius: 0 0 0 4px; transform: none; } }

/* ── 進場動態（照舊站：捲到才出現；位移 20px；放大的從 0.3 倍開始；時間各段不同，寫在 data-reveal-time） ── */
.js [data-reveal] { visibility: hidden; }
.js [data-reveal].is-in { visibility: visible; animation: var(--reveal-name) var(--reveal-time, 1s) .01s both; }
[data-reveal="fade"] { --reveal-name: fade; }
[data-reveal="fade-up"] { --reveal-name: fade-up; }
[data-reveal="fade-right"] { --reveal-name: fade-right; }
[data-reveal="zoom-in"] { --reveal-name: zoom-in; }
[data-reveal-time="1.2"] { --reveal-time: 1.2s; }
[data-reveal-time="1.5"] { --reveal-time: 1.5s; }
[data-reveal-time="1.6"] { --reveal-time: 1.6s; }
[data-reveal-time="2.5"] { --reveal-time: 2.5s; }
@keyframes fade { from { opacity: 0; } }
@keyframes fade-up { from { opacity: 0; transform: translateY(20px); } }
@keyframes fade-right { from { opacity: 0; transform: translateX(20px); } }
@keyframes zoom-in { from { opacity: 0; transform: scale(.3); } 50% { opacity: 1; } }

/* ═════ 481 以上 ═════ */
@media (min-width: 481px) {
  .hero { margin: 0 0 32%; padding: 20% 0 0; }
  .hero__logo { width: 180px; margin: 0 calc(50% - 90px); }
  .hero__text { margin: 8% 15% 12%; }
  .hero__sub { margin: 13% 0 0; }

  .blk__t { width: 60%; margin: 0 20%; }
  .blk__i { margin: 30px 0; }
  .s1, .s3 { padding: 60px 0; }
  .s3__i { width: 60%; margin: 30px 20%; }
  .line { margin: 30px 10% 30px 0; }
  .line--flip { margin: 30px 0 30px 10%; }

  .carousel__arrow { top: 45%; width: 16px; height: 35px; }
  .carousel__arrow::after { inset: -5px -14px; }
  .carousel__arrow--prev { left: 12px; }
  .carousel__arrow--next { right: 12px; }
  .chev { top: 10px; font-size: 1.35em; }

  .contact { width: 80%; margin: 60px 10%; }
  .contact__sub { width: 90%; margin: 25px 5% 30px; }
  .form__field { margin: 12px 0; }
  .form__label { letter-spacing: 3px; }
  .form__input { padding: 6px; }
  .form__consent { font-size: 1.15em; }
  .form__code { margin: 40px 0; }
  .form__btn { font-size: 1.35em; }
}

/* ═════ 769 以上：桌機版面（文字與圖左右排） ═════ */
@media (min-width: 769px) {
  .only-pc { display: block !important; }
  .only-ph { display: none !important; }

  .hero { margin: 0 0 10%; padding: 3% 0 0; }
  .hero__logo { width: 120px; margin: 0 calc(95% - 120px) 0 5%; }
  .hero__text { margin: 7% 15% 0; }
  .hero__sub { margin: 4% 0 0; }

  .s1, .s3 { padding: 80px 0 60px 5%; }
  .s2 { padding: 60px 5% 60px 0; }
  .s1__t, .s3__t { width: 31%; margin: 0 2% 0 0; }
  .s2__t { width: 31%; margin: 0; }
  .blk__body { margin-top: 35px; }
  .blk__i, .s3__i { width: 67%; margin: 0; }
  .s1__i { padding: 0 0 8px; }
  .s2__i { margin: 0 2% 0 0; }
  .s2__it { left: 3%; width: 43%; }
  .line { width: 75%; margin: 50px 0 50px 25%; }
  .line--flip { margin: 50px 25% 50px 0; }

  .carousel__arrow { height: 40px; }
  .carousel__arrow::after { inset: -2px -14px; }
  .carousel__arrow--prev { left: 20px; }
  .carousel__arrow--next { right: 10px; }
  .chev { top: 12px; }
  /* 第三區的輪播：一次兩張，每張左右各留 2%；照舊站沒有箭頭（自動換，也可以拖） */
  .carousel--pair .carousel__slide { flex-basis: 50%; }
  .carousel--pair .carousel__slide picture { padding: 0 2%; }
  .carousel--pair .carousel__nav { display: none; }

  .contact { width: 70%; margin: 80px 15%; }
  .contact__sub { margin: 30px 5% 40px; }
  .form__field { margin: 15px 0; }
  .form__consent { margin: 35px 0 0; font-size: 1.35em; }
  .form__code { margin: 50px 0; }
  .form__btn { font-size: 1.65em; }
  .bottom { margin: 80px 5% 50px; font-size: 1.25em; }
}

/* ═════ 1025 以上 ═════ */
@media (min-width: 1025px) {
  .hero { margin: 0 0 13%; padding: 2% 0 0; }
  .hero__logo { width: 160px; margin: 0 calc(95% - 160px) 0 5%; }
  .hero__sub { margin: 6% 0 0; }

  .s1, .s3 { padding: 100px 0 80px 5%; }
  .s2 { padding: 120px 5% 120px 0; }
  .s1__t, .s3__t { width: 28%; margin: 0 5% 0 0; }
  .s2__t { width: 25%; }
  .s2__i { width: 70%; margin: 0 5% 0 0; }
  .line { margin: 60px 0 60px 25%; }
  .line--flip { margin: 60px 25% 60px 0; }

  .carousel__arrow { top: calc(50% - 32.5px); width: 23px; height: 65px; }
  .carousel__arrow::after { inset: 0 -11px; }
  .carousel__arrow--prev { left: 30px; }
  .carousel__arrow--next { right: 30px; }
  .chev { top: 20px; font-size: 1.85em; }

  .contact { width: 500px; margin: 120px calc(50% - 250px); }
  .contact__sub { margin: 30px 5% 50px; }
  .form__label { font-size: 1.25em; }
}

/* ═════ 1441 以上：第一區的留白再放大 ═════ */
@media (min-width: 1441px) {
  .s1 { padding: 140px 0 120px 5%; }
  .s1__t { width: 25%; }
  .s1__i { width: 70%; }
  .s1 .blk__body { margin-top: 50px; }
}

/* ═════ 680 以下：浮動按鈕改成底部一排 ═════ */
@media (max-width: 680px) {
  .shortcuts { right: 0; bottom: 0; width: 100%; }
  .shortcuts a { width: 33.4%; height: 50px; margin: 0; font-size: 1.05em; background: var(--sc-bar); border: 0; border-top: 3px solid var(--sc-ink); border-radius: 0; }
  .shortcuts a:not(:last-child) { width: calc(33.3% - 1px); border-right: 1px solid #999; }
  .shortcuts a:hover { background: var(--sc-ink); }
  .shortcuts a span { display: inline-block; }
  /* 後台刪掉一顆時（照昭揚八德、藝文 2026-11-27 的修法）：剩下的平分整排，不留空位；
     分隔線改成只畫在看得到的按鈕之間，刪掉的是最右邊那顆時才不會在螢幕邊多一條線。三顆都在時不會套用。 */
  .shortcuts__in:has(a[hidden]) a { flex: 1 1 0; width: auto; border-right: 0; }
  .shortcuts__in:has(a[hidden]) a:not([hidden]) ~ a:not([hidden]) { border-left: 1px solid #999; }
  .ico { margin-right: 10px; }
}
@media (max-width: 480px) {
  .shortcuts a { height: 40px; font-size: 14px; }
  .ico { height: 1em; margin-right: 3px; }
  .ico--fb { width: .625em; }
  .ico--pin { width: .75em; }
  .ico--tel { width: 1em; }
}

/* 尊重「減少動態效果」：不做進場動畫、送出中的細線不跑 */
@media (prefers-reduced-motion: reduce) {
  .js [data-reveal], .js [data-reveal].is-in { visibility: visible; animation: none; }
  .modal[open], .modal[open]::backdrop { animation: none; }
  .form__btn.is-sending::after { animation: none; width: 100%; }
  .toast { transition: none; }
}
