﻿/* ════════════════════════════════════════════════════════════════════════
   English Aloha Teaching Review ── 本系統新增的樣式
   ────────────────────────────────────────────────────────────────────────
   顏色、字體、圓角沿用 css/aloha.css 的設計變數;類別以 tr- 開頭。
     1. 首頁(Default.aspx):沿用 aloha-landing.css 的 lp- 區塊,這裡只放新增的指標卡、四大維度、結尾按鈕
     2. 合約(Register.aspx 第 4 段、Contract.aspx):條文框、同意勾選、簽名板
     3. 已簽合約的文件版面與列印(瀏覽器「列印 → 另存為 PDF」)
   ════════════════════════════════════════════════════════════════════════ */

/* ── 1. 首頁 ── */
/* 標題第二行整句同一大小(原首頁的 em 是較小的第二行;這裡是句子中間的強調)*/
.tr-lp .lp-hero .lp-h1 { font-size: clamp(2.2rem, 4.2vw, 3.6rem); line-height: 1.08; }
.tr-lp .lp-hero .lp-h1 em { display: inline; margin: 0 0 0 .26em; font-size: 1em; line-height: inherit; }
/* 中文介面(i18n.js 把 html 的 lang 設為 zh-TW):中文字之間不留空白 */
html:lang(zh) .tr-lp .lp-hero .lp-h1 em { margin-left: 0; }
.tr-sep { color: var(--line); font-weight: 400; }
.tr-lp .lp-kicker-badge { flex-wrap: wrap; row-gap: 2px; }

.tr-stats .lp-stats-grid > div { align-content: start; }
.tr-stat-label { font-weight: 800; font-size: .84rem; color: var(--ink-soft); }
.tr-stats .lp-stats-grid strong { margin-top: 2px; }
.tr-stats .lp-stats-grid .tr-stat-sub { font-weight: 800; font-size: .76rem; letter-spacing: .02em; color: var(--lp-pop-deep); }

.tr-dims-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.tr-dim { padding: 24px 24px 20px; gap: 10px; transition: border-color .15s ease, transform .15s ease; }
.tr-dim:hover { border-color: var(--primary); transform: translateY(-2px); }
.tr-dim-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.tr-tag { background: var(--card); border: 2px solid var(--line); border-radius: 999px; padding: 2px 12px; font-weight: 800; font-size: .76rem; color: var(--lp-deep); }
.tr-checks { list-style: none; margin: 6px 0 0; padding: 12px 0 0; border-top: 2px dashed var(--line); display: grid; gap: 6px; }
.tr-checks li { position: relative; padding-left: 26px; font-weight: 700; font-size: .92rem; color: var(--ink-soft); }
.tr-checks li::before { content: "\2713"; position: absolute; left: 0; top: 0; width: 19px; height: 19px; border-radius: 50%; background: var(--leaf); color: #fff; font-size: .72rem; font-weight: 800; display: grid; place-items: center; }

.tr-end .lp-h2 { max-width: 22ch; margin-left: auto; margin-right: auto; }
.tr-end-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px 18px; }
.aloha .tr-btn-ghost { background: transparent; color: #fff; border: 2px solid rgba(255, 255, 255, .7); box-shadow: none; }
.aloha .tr-btn-ghost:hover, .aloha .tr-btn-ghost:focus-visible { background: rgba(255, 255, 255, .14); color: #fff; }

@media (max-width: 760px) {
    .tr-dims-grid { grid-template-columns: minmax(0, 1fr); }
    .tr-end-actions .aloha-btn { width: 100%; }
}

/* ── 2. 合約與簽名 ── */
.tr-summary { display: flex; flex-wrap: wrap; gap: 8px 22px; background: #fff8e6; border: 2px solid #f6dfa0; border-radius: var(--radius-sm); padding: 10px 16px; margin: 6px 0 14px; font-size: .9rem; }
.tr-summary strong { color: #6b4a00; }
.tr-contract {
    max-height: 340px; overflow-y: auto; background: var(--bg); border: 2px solid var(--line); border-radius: var(--radius-sm);
    padding: 16px 18px; font-size: .88rem; line-height: 1.6; color: var(--ink);
}
.tr-contract:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
.tr-contract-open { max-height: none; }
.tr-contract-title { margin: 0 0 12px; font-family: var(--display); font-weight: 800; font-size: 1.05rem; line-height: 1.3; color: var(--primary-strong); text-align: center; }
.tr-contract-title small { font-family: var(--ui); font-size: .78rem; letter-spacing: .04em; color: var(--ink-soft); }
.tr-article + .tr-article { margin-top: 12px; }
.tr-article h4 { margin: 0 0 4px; font-size: .92rem; font-weight: 800; color: var(--ink); }
.tr-article p { margin: 0 0 6px; }
.tr-article em { color: var(--ink-soft); }

.tr-consent { display: flex; align-items: flex-start; gap: 10px; margin: 14px 0; padding: 10px 14px; background: var(--card); border: 2px solid var(--line); border-radius: var(--radius-sm); font-size: .9rem; font-weight: 700; cursor: pointer; }
.tr-consent input { width: 18px; height: 18px; margin-top: 3px; flex: none; accent-color: var(--primary); }

.tr-sign { margin-top: 6px; }
.tr-sign-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.tr-sign-clear { border: 0; background: none; padding: 4px 2px; font-weight: 800; font-size: .84rem; color: var(--lp-pop-deep, #c21f5d); cursor: pointer; }
.tr-sign-clear:hover, .tr-sign-clear:focus-visible { text-decoration: underline; }
.tr-sign-area { position: relative; border: 2px dashed var(--line); border-radius: var(--radius-sm); background: #fff; overflow: hidden; }
.tr-sign-pad { display: block; width: 100%; height: 150px; touch-action: none; cursor: crosshair; }
.tr-sign-ph { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: 10px; text-align: center; pointer-events: none; color: #94a3b8; font-size: .86rem; font-weight: 700; }
.tr-sign-msg { margin: 6px 0 0; font-weight: 800; font-size: .88rem; color: #b42318; }

/* ── 3. 已簽合約(文件版面)── */
.tr-doc-actions { margin-bottom: 14px; }
.tr-doc {
    background: #fff; color: #0f172a; border: 2px solid var(--line); border-radius: var(--radius-sm);
    padding: clamp(18px, 4vw, 40px); max-width: 860px; font-size: .86rem; line-height: 1.6;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang TC", "Microsoft JhengHei", sans-serif;
}
.tr-doc-head { border-bottom: 2px solid #1e1b4b; padding-bottom: 12px; margin-bottom: 16px; text-align: center; }
.tr-doc-head h2 { margin: 0 0 4px; font-size: 1.05rem; font-weight: 800; color: #1e1b4b; }
.tr-doc-head h3 { margin: 0; font-size: .86rem; font-weight: 700; color: var(--primary-strong); }
.tr-doc-head p { margin: 4px 0 0; font-size: .74rem; color: #64748b; }
.tr-doc table { width: 100%; border-collapse: collapse; }
.tr-doc-parties td { width: 50%; padding: 4px 0; vertical-align: top; }
.tr-doc-body { border-top: 1px solid #cbd5e1; margin-top: 10px; padding-top: 10px; }
.tr-doc-body .tr-article h4 { font-size: .86rem; }
.tr-doc-sign { border-top: 1px solid #1e1b4b; margin-top: 18px; }
.tr-doc-sign td { width: 50%; padding-top: 12px; vertical-align: top; }
.tr-doc-label { font-weight: 800; }
.tr-doc-platform { margin-top: 8px; font-size: 1rem; font-weight: 800; color: #1e1b4b; }
.tr-doc-ok { margin-top: 4px; font-size: .76rem; color: #15803d; font-weight: 700; }
.tr-doc-sigline { height: 70px; margin-top: 6px; border-bottom: 1px solid #94a3b8; display: flex; align-items: flex-end; }
.tr-doc-sig { max-height: 64px; max-width: 240px; }
.tr-doc-small { margin-top: 4px; font-size: .72rem; color: #64748b; }
.tr-doc-foot { margin-top: 24px; padding-top: 6px; border-top: 1px dashed #e2e8f0; text-align: center; font-size: .68rem; color: #94a3b8; word-break: break-all; }

@media print {
    .aloha-topbar, .aloha-footer, .tr-no-print, #langSwitcher { display: none !important; }
    body.aloha { background: #fff !important; }
    .aloha-main { padding: 0 !important; }
    .tr-doc { border: 0; padding: 0; max-width: none; font-size: 10.5pt; }
}
