/* The 📱 Family app (ui/family-ui.js): children cards, a child's needs, care, supplies, the vaccination card, milestones.
   Builds on the Events app's look (css/events.css: .ev-card, .ev-btn, .ev-note). Phone first. */
.fam-card > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.fam-card strong { font: 800 14.5px var(--ui); }
.fam-card span { font: 600 12px var(--ui); color: #5b5f66; }
.fam .fam-card .fam-face, .fam .fam-head .fam-face { font-size: 30px; line-height: 1; color: inherit; flex: none; }
.fam .fam-head .fam-face.big { font-size: 44px; }
.fam-tag { align-self: flex-start; margin-top: 2px; padding: 2px 8px; border-radius: 99px; background: #dcfce7; color: #15803d !important; font-weight: 800 !important; }
.fam-tag.bad { background: #fee2e2; color: #b91c1c !important; }
.fam-preg { background: #fdf2f8; border-radius: 16px; padding: 10px 12px; margin-bottom: 10px; font: 600 13px var(--ui); color: #6b2147; }
.fam-preg span { display: block; font-size: 12px; color: #86506b; margin-top: 2px; }
.fam-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.fam-head > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.fam-head strong { font: 800 18px var(--ui); }
.fam-head span { font: 600 12px var(--ui); color: #5b5f66; }
.fam-needs { background: #fff; border-radius: 16px; padding: 10px 12px; margin-bottom: 10px; box-shadow: 0 1px 3px rgba(0,0,0,.07); }
.fam-need { display: flex; align-items: center; gap: 8px; margin: 5px 0; }
.fam-need span { width: 88px; font: 700 12px var(--ui); color: #3a3d42; }
.fam-bar { flex: 1; height: 10px; border-radius: 99px; background: #ececef; overflow: hidden; }
.fam-bar i { display: block; height: 100%; border-radius: 99px; transition: width .4s; }
.fam-care { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.fam-care .ev-btn { flex: 1 1 46%; text-align: left; }
.fam-care .ev-btn small { font-weight: 600; opacity: .75; }
.fam-care .ev-btn:disabled { opacity: .5; }
.fam-jabs { background: #fff; border-radius: 16px; padding: 4px 12px; margin-bottom: 10px; box-shadow: 0 1px 3px rgba(0,0,0,.07); }
.fam-jabs > div { display: flex; justify-content: space-between; gap: 8px; padding: 7px 0; border-bottom: 1px solid #f0f0f2; font: 600 12.5px var(--ui); }
.fam-jabs > div:last-child { border-bottom: 0; }
.fam-jabs span { color: #5b5f66; text-align: right; }

/* 👗 Kids' Clothes (ui/kids-shop.js): the girl turning on the left, the dresses on the right (phones: above / below) */
#kidsShop { display: none; position: fixed; inset: 0; z-index: 30; font-family: var(--ui, system-ui); background: linear-gradient(135deg, #f7efe3, #efe2cf); }
#kidsShop.on { display: flex; }
#kidsShop .ks-stage { position: relative; flex: 1 1 45%; min-width: 0; }
#kidsShop .ks-stage canvas { width: 100%; height: 100%; display: block; touch-action: none; cursor: grab; }
#kidsShop .ks-hint { position: absolute; bottom: 10px; left: 0; right: 0; text-align: center; font-size: 12px; color: #7a6a55; pointer-events: none; }
#kidsShop .ks-panel { flex: 1 1 55%; min-height: 0; display: flex; flex-direction: column; background: #fffaf3; box-shadow: -4px 0 18px rgba(80, 50, 20, .12); min-width: 0; }
#kidsShop .ks-top { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid #eadfcf; font-size: 17px; color: #4a3520; }
#kidsShop .ks-x { border: 0; background: #f1e6d6; width: 36px; height: 36px; border-radius: 50%; font-size: 16px; cursor: pointer; }
#kidsShop .ks-body { flex: 1; overflow-y: auto; padding: 10px 14px 16px; -webkit-overflow-scrolling: touch; }
#kidsShop .ks-for { margin: 0 0 8px; color: #6b5641; font-size: 14px; }
#kidsShop .ks-kids, #kidsShop .ks-tabs { display: flex; gap: 6px; overflow-x: auto; margin-bottom: 10px; padding-bottom: 2px; }
#kidsShop .ks-kids button, #kidsShop .ks-tabs button { flex: none; border: 1px solid #e3d4bf; background: #fff; border-radius: 18px; padding: 7px 12px; font-size: 13px; color: #4a3520; cursor: pointer; white-space: nowrap; }
#kidsShop .ks-kids button.on, #kidsShop .ks-tabs button.on { background: #c2410c; border-color: #c2410c; color: #fff; }
#kidsShop .ks-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
#kidsShop .ks-card { display: flex; flex-direction: column; align-items: center; gap: 4px; border: 2px solid transparent; background: #fff; border-radius: 12px; padding: 8px 6px; cursor: pointer; box-shadow: 0 1px 3px rgba(80, 50, 20, .12); }
#kidsShop .ks-card.sel { border-color: #c2410c; }
#kidsShop .ks-card img { width: 56px; height: 56px; border-radius: 10px; object-fit: cover; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .1); }
#kidsShop .ks-card span { font-size: 12px; line-height: 1.2; color: #3d2b18; text-align: center; min-height: 2.4em; }
#kidsShop .ks-card small { font-size: 11px; color: #9a5b16; font-weight: 600; }
#kidsShop .ks-body { min-height: 0; }
#kidsShop .ks-foot { flex: none; padding: 8px 14px calc(10px + env(safe-area-inset-bottom)); border-top: 1px solid #eadfcf; background: #fffaf3; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
#kidsShop .ks-foot:empty { display: none; }
#kidsShop .ks-act { flex: 1 1 100%; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 8px 10px; background: #fff3e4; border-radius: 12px; }
#kidsShop .ks-act b { flex: 1 1 100%; color: #4a3520; }
#kidsShop .ks-act small { color: #b91c1c; }
#kidsShop .ks-note { flex: 1 1 100%; margin: 2px 0; font-size: 13px; color: #6b5641; }
#kidsShop .ks-empty { display: flex; flex-direction: column; gap: 6px; padding: 24px 6px; color: #6b5641; }
#kidsShop .ev-btn { min-height: 40px; }
@media (orientation: portrait), (max-width: 700px) {
  #kidsShop { flex-direction: column; }
  #kidsShop .ks-stage { flex: 0 0 40%; }
  #kidsShop .ks-panel { flex: 1 1 60%; box-shadow: 0 -4px 18px rgba(80, 50, 20, .12); border-radius: 16px 16px 0 0; }
}
body.kids-shop #hudChat, body.kids-shop #gunSlot { display: none !important; }
/* the Family app's 👗 Dresses (ui/family-ui.js) */
.fam-dress { display: flex; flex-wrap: wrap; gap: 6px; }
.fam-dress .ev-btn img { width: 18px; height: 18px; border-radius: 4px; vertical-align: -4px; margin-right: 4px; }
