/* หน้ารวม /home (สเปก Phase6-F6-5 ข้อ ข · ร่าง 1 ซ้าย + กลาง) — ต่อจาก tk-ui.css · สีจากตัวแปรธีมเท่านั้น · ไม่มี style ในแท็ก (CSP)
   แถบบน: ทักษา · ปุ่มภาษา · ชิปบัญชี (เข้าสู่ระบบ / ชื่อผู้ใช้ ▾ → เมนูเล็กลอยใต้ชิป) · เส้นคั่นใต้แถบ
   การ์ดใหญ่ (ถามหมอดู · ดูดวงสด) ขอบทอง พื้นทองจาง · การ์ดธรรมดา (orapet) ขอบจาง · หมวดของโปร: หัวหมวด + ช่องเล็กมีไอคอน (งานหมอดู) / ช่องคำ ๒ คอลัมน์ (เครื่องมือ · หน้าที่ลูกค้าเห็น)
   ป้าย TH (อังกฤษ) มุมขวาบนของช่อง/การ์ด → ช่องเว้นที่ด้านบนไว้ ป้ายไม่ทับคำ */
.home-page{max-width:560px}
.home-top{padding-bottom:14px;border-bottom:1px solid var(--rule-soft)}
.home-links{display:flex;flex-direction:column;gap:16px;margin-top:20px}
.home-locked{margin:16px 0 0;padding:14px 16px;border:1.5px solid var(--accent);border-radius:16px;background:var(--sheet);color:var(--ink);font-weight:600}

/* ---------- ชิปบัญชี + เมนูเล็ก ---------- */
.home-who{display:flex;align-items:center;min-width:0}
.home-chip{gap:6px;max-width:12em;border-radius:14px}
.home-user{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.home-menu{position:relative}
.home-menu summary{list-style:none}
.home-menu summary::-webkit-details-marker{display:none}
.home-menu-box{position:absolute;top:calc(100% + 8px);right:0;z-index:5;display:flex;flex-direction:column;gap:10px;min-width:180px;padding:12px;
  border:1.5px solid var(--tk-line);border-radius:16px;background:var(--sheet);color:var(--ink)}
.home-role{margin:0;font-size:17px;font-weight:700;line-height:1.4;color:var(--legend)}
.home-logout{width:100%}
html[data-theme="b"] .tk-top .home-menu-box .tk-btn{background:var(--sheet);border-color:var(--tk-line);color:var(--ink)}
html[data-theme="b"] .tk-top .home-menu-box :focus-visible{outline-color:var(--focus)}

/* ---------- การ์ด ---------- */
.home-card{position:relative;padding:20px 18px;border:1.5px solid var(--rule-soft);border-radius:22px;background:var(--sheet)}
.home-card.is-hero{border:2px solid var(--accent);background:linear-gradient(160deg, color-mix(in srgb, var(--accent) 16%, var(--sheet)), var(--sheet) 70%)}
.home-card-t{margin:0;font-size:28px;font-weight:700;line-height:1.25;color:var(--ink);overflow-wrap:anywhere}
.home-card.is-hero .home-card-t{font-size:30px;color:var(--title)}
.home-lead{margin:8px 0 0;font-size:18px;line-height:1.5;color:var(--muted)}
.home-go{width:100%;margin-top:18px}
.home-go-alt{border-color:var(--accent);background:transparent;color:var(--legend);font-weight:700}
.home-stats{display:flex;flex-wrap:wrap;gap:8px;margin:10px 0 0}
.home-stat{display:inline-flex;align-items:center;padding:2px 12px;border:1.5px solid var(--accent);border-radius:999px;color:var(--legend);font-size:16px;font-weight:600;line-height:1.5}

/* ---------- หมวดของโปร/แอดมิน ---------- */
.home-sec{display:flex;flex-direction:column;gap:12px}
.home-sec + .home-sec{margin-top:10px}
.home-sec-h{margin:0;font-size:19px;font-weight:700;line-height:1.3;color:var(--ink)}
.home-tiles{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(0,1fr);gap:12px}
.home-tile{position:relative;flex-direction:column;align-items:center;justify-content:center;gap:8px;min-height:104px;padding:30px 6px 12px;min-width:0}
.home-tile .tk-ico{width:36px;height:36px;stroke-width:1.7}
.home-tile-t{font-size:18px;font-weight:700;line-height:1.2;text-align:center;overflow-wrap:anywhere}
.home-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.home-cell{position:relative;align-items:center;justify-content:center;min-height:76px;padding:26px 6px 14px;min-width:0}
.home-cell-t{font-size:19px;font-weight:700;line-height:1.2;text-align:center;overflow-wrap:anywhere}
/* จอแคบกว่า 360px: ช่องห่างและขอบในแคบลง ชื่อได้ที่มากขึ้น */
@media (max-width:359px){ .home-tiles,.home-grid{gap:8px} .home-tile,.home-cell{padding-left:2px;padding-right:2px} .home-chip{max-width:9em} }
