/* css/s-parent.css — 담당: parent. 접두 p- 만 정의(BUILD 8-4). 8-3 컴포넌트는 고치지 않고 덧붙여 씀.
   보호자 화면: 본문 16px 이상, 누르는 곳 48px 이상, 색만으로 구분하지 않음(모양·글자 함께), 빨간색·막대·채움 비율 없음. */

.p-screen {
  color: var(--parent-text, #334155);
  word-break: keep-all;
  overflow-wrap: anywhere;
}
.p-screen > * + * { margin-top: var(--sp-3, 12px); }

/* 머리 */
.p-head { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-2, 8px); min-height: var(--header-h, 56px); padding: 0; }
.p-head__title { font-size: var(--fs-title, 24px); font-weight: 700; margin: 0; }
.p-head__title:focus { outline: none; }
.p-head__title:focus-visible { outline: 3px solid var(--focus, #334155); outline-offset: 3px; }
.p-head__sub { margin-top: 0; }

/* 글 줄 */
.p-line { margin: 6px 0; font-size: var(--fs-body, 16px); line-height: 1.55; }
.p-strong { margin: 6px 0; font-size: var(--fs-body, 16px); font-weight: 700; line-height: 1.5; }
.p-muted { margin: 4px 0; font-size: var(--fs-small, 14px); color: var(--parent-muted, #6B7280); line-height: 1.5; }
.p-small { margin: 2px 0; font-size: var(--fs-small, 14px); line-height: 1.5; }
.p-ok { margin: 6px 0; font-weight: 700; color: #2F5D4A; }
.p-ok::before { content: "✓ "; }
.p-tag {
  display: inline-block; margin: 4px 0; padding: 2px 10px; border-radius: var(--radius-pill, 999px);
  border: 1px solid var(--parent-blue, #B8C4D8); background: var(--parent-bg, #F7F8FB); font-size: var(--fs-small, 14px);
}
.p-note-line {
  margin: 8px 0; padding: 10px 12px; border-left: 4px solid var(--parent-blue, #B8C4D8);
  background: var(--parent-bg, #F7F8FB); border-radius: 8px; line-height: 1.55;
}
.p-check {
  margin: 12px 0; padding: 12px; border: 1px dashed var(--parent-muted, #6B7280); border-radius: var(--radius-sm, 12px);
  font-size: var(--fs-small, 14px); line-height: 1.55; background: var(--parent-surface, #fff);
}
.p-list { margin: 6px 0; padding-left: 1.2em; line-height: 1.6; }
.p-list li + li { margin-top: 4px; }
.p-steps li { margin-bottom: 6px; }

/* 줄 배치 */
.p-row { display: flex; align-items: center; gap: var(--sp-2, 8px); flex-wrap: wrap; margin: 8px 0; }
.p-row--wrap { flex-wrap: wrap; }
.p-stack { display: flex; flex-direction: column; gap: var(--sp-2, 8px); margin: 8px 0; }
.p-stack > * { width: 100%; }

/* 단추 크기(보호자 48px 이상) */
.p-screen button, .p-sheet button, .p-tel { min-height: var(--touch-parent, 48px); }
.p-chip, .theme-parent .p-chip { min-height: var(--touch-parent, 48px); min-width: 48px; padding: 0 14px; font-size: var(--fs-body, 16px); }
.p-chip[aria-pressed="true"] { font-weight: 700; }
.p-chip[aria-pressed="true"]::before { content: "✓ "; }
.p-switch { min-width: 72px; }
.p-choice { text-align: left; }
/* 보기 단추 목록: 한 줄·두 줄 모두 왼쪽 정렬(들쭉날쭉하지 않게) */
.p-weekly .p-choice, .p-sheet .p-choice { justify-content: flex-start; text-align: left; }

/* 카드 */
.p-card { padding: var(--sp-4, 16px); background: var(--parent-surface, #fff); border-color: var(--parent-border, #E8ECF4); }
.p-card__title { font-size: var(--fs-section, 20px); font-weight: 700; margin: 0 0 6px; }
.p-todos { display: flex; flex-direction: column; gap: var(--sp-3, 12px); }
.p-task__title { font-size: 18px; font-weight: 700; margin: 0 0 4px; }
.p-task__note { margin: 0 0 8px; color: var(--parent-muted, #6B7280); font-size: var(--fs-small, 14px); }
.p-light-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap;
  padding: 8px 12px; border: 1px solid var(--parent-border, #E8ECF4); border-radius: var(--radius-sm, 12px); background: var(--parent-surface, #fff);
}
.p-suggest { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--parent-border, #E8ECF4); }
.p-coach { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--parent-border, #E8ECF4); }
.p-thanks { font-size: 18px; }
.p-stats { padding: 4px 2px; }

/* A 카드: 차분한 색, 전화 단추 크게 */
.p-acard { padding: var(--sp-4, 16px); border-radius: var(--radius-card, 24px); border: 2px solid var(--parent-accent, #5A3E2B); }
.p-acard__head { font-size: var(--fs-section, 20px); font-weight: 700; margin: 0 0 6px; }
.p-acard__head::before { content: "! "; }
.p-acard__body { line-height: 1.6; margin: 8px 0; }
.p-acard__said { margin: 8px 0; padding: 8px 12px; background: var(--parent-surface, #fff); border-radius: 8px; font-weight: 700; }
/* 전화 버튼: 같은 격자 칸·같은 높이. button+date 는 버튼 바로 아래 확인일 한 줄. 번호 글줄(117 등)은 버튼이 아니라 아래 목록 */
.p-telblock { margin: 10px 0; min-width: 0; }
.p-acard__tels, .p-tels {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 8px; margin: 0; align-items: start;
}
.p-tel-wrap { display: flex; flex-direction: column; gap: 2px; min-width: 0; align-self: start; }
.p-tel {
  display: flex; align-items: center; justify-content: center; gap: 4px; min-width: 0; width: 100%; box-sizing: border-box;
  min-height: var(--touch-parent, 48px); padding: 4px 10px; line-height: 1.2;
  border-radius: var(--radius-button, 28px); border: 2px solid var(--parent-accent, #5A3E2B);
  background: var(--parent-surface, #fff); color: var(--parent-accent, #5A3E2B); font-size: 18px; font-weight: 700; text-decoration: none;
  white-space: normal; overflow: hidden;
}
.p-tel > svg { flex: 0 0 auto; }
.p-tel__t { min-width: 0; white-space: nowrap; }
.p-tel__date { padding: 0 4px; line-height: 1.4; }
.p-tel-lines { margin: 8px 0 0; }
.p-tel:focus-visible { outline: 3px solid var(--focus, #334155); outline-offset: 3px; }
.p-mem { font-weight: 700; }
.p-mem__t { margin: 0; }
.p-mem__sub { margin-top: 4px; font-weight: 400; }
.p-mem--full button, .p-clock button { margin-top: 8px; }
.p-tel__name { padding: 0 4px; line-height: 1.4; }

/* 접힘 */
.p-fold { background: var(--parent-surface, #fff); border: 1px solid var(--parent-border, #E8ECF4); border-radius: var(--radius-sm, 12px); }
.p-fold__head { min-height: 48px; display: flex; align-items: center; padding: 0 var(--sp-4, 16px); font-weight: 700; cursor: pointer; list-style: none; }
.p-fold__head::-webkit-details-marker { display: none; }
/* 펼침 표시는 base.css .fold > summary::after 꺾쇠 하나만(글자 화살표를 덧붙이지 않음) */
.p-fold__body { padding: 0 var(--sp-4, 16px) var(--sp-4, 16px); }
.p-fold--big > .p-fold__head { font-size: var(--fs-section, 20px); min-height: 56px; }
.p-fold .p-fold { margin: 8px 0; }

/* 우리 아이 지도 */
.p-map__title { font-size: 18px; margin: 8px 0; }
.p-start { margin: 8px 0 12px; padding: 12px; border: 1px solid var(--parent-blue, #B8C4D8); border-radius: var(--radius-sm, 12px); }
.p-start__title { margin: 0 0 6px; font-size: 18px; }
.p-start__list { margin: 4px 0 8px; padding-left: 1.4em; font-weight: 700; line-height: 1.6; }
.p-bands { margin: 12px 0; }
.p-bands__title { margin: 0 0 6px; font-size: 17px; }
.p-band { border-top: 1px solid var(--parent-border, #E8ECF4); }
.p-band__sum {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 12px;
  min-height: 48px; padding: 6px 0; cursor: pointer; list-style: none;
}
.p-band__sum::-webkit-details-marker { display: none; }
.p-band__name { font-weight: 700; }
.p-band__val { display: inline-flex; align-items: center; gap: 4px; }
.p-band__shape { display: inline-block; width: 1.3em; text-align: center; font-size: 18px; line-height: 1; }
.p-band--high .p-band__shape { color: var(--parent-accent, #5A3E2B); }
.p-band--unknown .p-band__val { color: var(--parent-muted, #6B7280); }
.p-band__star { font-weight: 700; }
.p-band__body { padding: 0 0 10px 1.3em; }
.p-band__desc { margin-top: 6px; }
.p-dots { letter-spacing: 1px; }
.p-knowdo-note { margin: 4px 0 8px; }
.p-why { margin: 4px 0; }
.p-growth { padding: 8px 0; border-top: 1px solid var(--parent-border, #E8ECF4); }
.p-growth__name { display: block; }
.p-hope, .p-voice, .p-needle, .p-friends-box { margin: 12px 0; }
.p-hope h4, .p-voice h4, .p-needle h4, .p-friends-box h4 { margin: 0 0 4px; font-size: 16px; }
.p-refer { margin: 12px 0; padding: 14px; border-radius: var(--radius-sm, 12px); }
.p-refer__head { margin: 0 0 6px; font-size: 18px; }
.p-refer--folded { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.p-friends { list-style: none; margin: 6px 0; padding: 0; }
.p-friend { display: flex; align-items: center; gap: 8px; min-height: 36px; }
.p-friend__badge {
  display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto;
  width: 32px; height: 32px; border-radius: 50%; border: 2px solid var(--parent-text, #334155);
  font-weight: 700; background: var(--parent-surface, #fff);
}
.p-ledger { font-size: var(--fs-small, 14px); }

/* 함께 돕기 */
.p-help-grid { display: grid; grid-template-columns: 1fr; gap: 8px; margin-top: 8px; }
@media (min-width: 520px) { .p-help-grid { grid-template-columns: 1fr 1fr; } }
.p-help-btn { width: 100%; }

/* 바닥 */
.p-foot { margin-top: var(--sp-6, 24px); padding-top: var(--sp-4, 16px); border-top: 1px solid var(--parent-border, #E8ECF4); }

/* 처음 켬 */
.p-setup { display: flex; flex-direction: column; gap: 12px; padding-top: 24px; }
.p-setup__q { font-size: var(--fs-question, 22px); font-weight: 700; margin: 0; line-height: 1.4; }
.p-setup__q:focus { outline: none; }
.p-setup__lead { font-size: 18px; line-height: 1.6; }
.p-age-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.p-age { min-height: 56px; font-size: 18px; }
.p-age--other { grid-column: span 4; }
.p-input {
  width: 100%; max-width: 100%; box-sizing: border-box; min-height: 48px; padding: 10px 12px;
  font: inherit; font-size: var(--fs-body, 16px); color: var(--parent-text, #334155);
  border: 2px solid var(--parent-blue, #B8C4D8); border-radius: var(--radius-sm, 12px); background: var(--parent-surface, #fff);
}
.p-input:focus-visible { outline: 3px solid var(--focus, #334155); outline-offset: 2px; }
.p-textarea { min-height: 88px; resize: vertical; }
.p-row .p-input { flex: 1 1 160px; width: auto; }

/* 시트 안 */
.p-sheet { display: flex; flex-direction: column; gap: 8px; color: var(--parent-text, #334155); word-break: keep-all; overflow-wrap: anywhere; }
.p-sheet__sec { margin: 6px 0; padding-bottom: 10px; border-bottom: 1px solid var(--parent-border, #E8ECF4); }
.p-sheet__sec:last-child { border-bottom: 0; }
.p-sheet__sub { margin: 8px 0 6px; font-size: 16px; }
.p-set-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 52px; }
.p-set-row__label { display: flex; flex-direction: column; flex: 1 1 auto; min-width: 0; font-size: var(--fs-body, 16px); }
/* 오른쪽 단추([켜짐]/[꺼짐]·[빼기]·[다시 넣기])는 라벨이 길어도 눌려 줄바꿈되지 않게 */
.p-set-row > button, .p-set-row .p-switch { flex: 0 0 auto; white-space: nowrap; min-width: 72px; }
/* 되돌릴 수 없는 [전체 지우기]: 구역을 따로 두고 굵은 테두리·글자(색만으로 구분하지 않음) */
.p-set-reset { border-top: 2px solid var(--parent-accent, #5A3E2B); padding-top: 6px; }
.p-danger, .theme-parent .secondary-button.p-danger, .p-sheet .secondary-button.p-danger { border: 2px solid var(--parent-accent, #5A3E2B); color: var(--parent-accent, #5A3E2B); font-weight: 700; }
.p-danger::before { content: "! "; }
.p-set-row__note { font-weight: 400; }
.p-set-block { margin: 8px 0; }
.p-model-stage { margin-top: 8px; }
.p-four { background: var(--parent-bg, #F7F8FB); border-radius: var(--radius-sm, 12px); padding: 8px 12px; }
.p-remin { margin: 8px 0; padding: 12px 14px; }
.p-remin__title { margin: 0 0 4px; font-size: 17px; }
.p-friend-card { margin: 8px 0; padding: 12px; }
.p-friend-card__head { display: flex; align-items: center; gap: 8px; }
.p-friend-card__head > strong { flex: 1 1 auto; }
.p-event { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.p-pd-guide { background: var(--parent-bg, #F7F8FB); border-radius: var(--radius-sm, 12px); padding: 10px 12px; }

/* 질문 시트 */
.p-ask__prog { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.p-ask__dots { display: flex; gap: 10px; align-items: center; }
.p-ask__dot { width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--parent-text, #334155); background: var(--parent-surface, #fff); box-sizing: border-box; }
.p-ask__dot[data-state="done"] { background: var(--parent-text, #334155); }
.p-ask__dot[data-state="current"] { width: 18px; height: 18px; background: var(--parent-blue, #B8C4D8); border-width: 3px; }
.p-ask__page { font-size: var(--fs-small, 14px); color: var(--parent-muted, #6B7280); }
.p-ask__head { margin-bottom: 0; }
.p-ask__q { font-size: 19px; line-height: 1.5; font-weight: 700; margin: 6px 0 10px; }
.p-ask__opts { display: flex; flex-direction: column; gap: 10px; }
.p-ask__opt { width: 100%; min-height: 56px; text-align: left; font-size: 17px; }
.p-ask__extra { margin-top: 10px; }
.p-ask__xopt { font-size: var(--fs-small, 14px); }
.p-ask__follow { margin-top: 14px; padding-top: 10px; border-top: 1px solid var(--parent-border, #E8ECF4); }
.p-ask__flabel { margin: 8px 0 4px; font-size: 16px; }
.p-ask__after { margin-top: 12px; display: flex; flex-direction: column; gap: 8px; }
.p-ask__nav { display: flex; justify-content: space-between; gap: 8px; margin-top: 16px; }

/* 쪽지·상담용 정리 미리보기(화면) */
.p-note-preview, .p-consult-preview {
  border: 1px solid var(--parent-border, #E8ECF4); border-radius: var(--radius-sm, 12px);
  background: var(--parent-surface, #fff); padding: 12px; max-width: 100%; overflow-x: auto;
}
.p-note__title { font-size: 18px; margin: 0 0 8px; }
.p-note__list { padding-left: 1.3em; line-height: 1.6; }
.p-note__extra { margin: 6px 0 0; line-height: 1.6; }
.p-note__end { font-weight: 700; margin-top: 8px; }
.p-consult { font-size: 14px; line-height: 1.5; color: #111; }
.p-consult h1 { font-size: 18px; margin: 0 0 4px; }
.p-consult h2 { font-size: 15px; margin: 12px 0 4px; }
.p-consult h3 { font-size: 14px; margin: 6px 0 2px; }
.p-consult small { font-weight: 400; color: #444; }
.p-consult p { margin: 4px 0; }
.p-consult__write { min-height: 3em; white-space: pre-wrap; border-bottom: 1px solid #999; }
.p-consult__table { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 12px; }
.p-consult__table th, .p-consult__table td { border: 1px solid #999; padding: 4px; vertical-align: top; text-align: left; word-break: keep-all; overflow-wrap: anywhere; }
.p-consult__table th:last-child, .p-consult__table td:last-child { width: 2.5em; text-align: center; }
.p-consult__note { font-size: 11px; color: #333; }
.p-consult__two { display: grid; grid-template-columns: 1fr; gap: 8px; }
@media (min-width: 560px) { .p-consult__two { grid-template-columns: 1fr 1fr; } }
.p-consult__foot { margin-top: 12px; padding-top: 8px; border-top: 1px solid #999; font-size: 11px; }

/* 인쇄: #print-area 안에서만 보임(design 8-2). 흑백으로도 구분되게 기호·선만 */
@media print {
  .p-consult, .p-note { color: #000; font-size: 10.5pt; }
  .p-consult__table { font-size: 9.5pt; }
  .p-consult__table tr, .p-consult section, .p-note { break-inside: avoid; }
  .p-consult__two { grid-template-columns: 1fr 1fr; }
}

/* 보호자 화면 폭: 360px 에서 가로 넘침 없음 */
.p-screen img, .p-screen svg, .p-sheet img, .p-sheet svg { max-width: 100%; height: auto; }
@media (max-width: 380px) {
  .p-age-grid { grid-template-columns: repeat(4, 1fr); gap: 6px; }
  .p-tel { font-size: 17px; }
  .p-acard__tels, .p-tels { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
  .p-ask__nav { flex-wrap: wrap; }
}

/* 움직임 줄이기: 이 파일은 애니메이션을 쓰지 않음. 접힘 화살표만 바뀜 */
