/* aed.ayo.pe.kr — 자동심장충격기(AED) 독자 스킨 (2026-09-27 사이트 고유 디자인 규칙).
 *
 * 콘셉트: **비상 안내 표지판 × 응급처치 단계 카드**. 급할 때 보는 사이트다 — AED 보관함 위의 초록 안전 표지
 * (흰 하트 + 번개), 복도의 초록 유도 표지 화살표, 심폐소생술 단계 카드의 큰 번호로 짠다.
 * 장식보다 **대비·큰 숫자·한눈에 읽히는 표지**가 먼저다.
 * site.css(디자인 A) 위에 덮어쓰고 전부 body.site-aed 아래로 가둔다 — 다른 사이트에 새지 않는다.
 *
 *   헤더   : 안전 초록 띠 + 하트·번개 표지(CSS 도형) · 아래 "119 신고 → AED" 안내 줄
 *   탭     : 흰 테두리 표지판
 *   요약표 : 설치 위치 표지 — 굵은 초록 테 + 모노 숫자
 *   질답   : 응급처치 단계 카드 — 질문마다 초록 사각 단계 번호(STEP), 답은 굵은 왼쪽 선
 *   목록   : 유도 표지 줄 — 오른쪽 화살표 원, 왼쪽 초록 막대
 *   허브   : 초록 표지판 칩(흰 글씨 + 화살표)
 *   글꼴   : 제목 Gothic A1 900 · 본문 Gothic A1 · 숫자 Roboto Mono
 *
 * ⚠️ 광고 유닛(<ins>·.ad-top·.ad-row 안쪽)에는 배경·테두리·라벨을 씌우지 않는다(site.css 애드센스 절).
 * ⚠️ 질문(h2)과 답(p) 사이에 요소를 끼우지 않는다 — 장식은 ::before/::after 로만.
 * ⚠️ 이용시간은 설치기관 등록 참고값이다(SITES.md) — "항상 사용 가능" 같은 표식을 디자인이 만들지 않는다.
 */

body.site-aed {
  --fg: #111a15;
  --fg-soft: #36433b;
  --muted: #66746b;
  --line: #d3ddd6;
  --line-soft: #e8eee9;
  --bg: #ffffff;
  --bg-soft: #f1f6f2;
  --accent: #007a43;          /* 안전 초록(ISO 7010 계열) */
  --accent-strong: #005c32;
  --accent-soft: #dff1e6;
  --accent-wash: #f1faf4;
  --accent-line: #9fd2b3;
  --safe: #00874a;
  --heart: #d7263d;
  --radius: 6px;
  --wrap: 880px;
  --mono: "Roboto Mono", ui-monospace, monospace;
  background: #f5f7f5;
  font-family: "Gothic A1", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  font-weight: 500;
}
body.site-aed a { color: var(--accent); }

body.site-aed main,
body.site-aed .site-foot,
body.site-aed .ad-top,
body.site-aed .top-search { max-width: var(--wrap); }

/* ── 헤더: 안전 표지 띠 ─────────────────────────────────────────────── */
body.site-aed .site-head {
  position: relative;
  max-width: none;
  margin: 0 0 44px;
  padding: 18px max(20px, calc((100% - var(--wrap)) / 2 + 20px));
  border: 0;
  background: var(--safe);
  box-shadow: inset 0 -4px 0 rgba(0, 0, 0, .18);
}
/* 헤더 아래 안내 줄 */
body.site-aed .site-head::after {
  content: "심정지 의심 → 119 신고 → 가까운 AED · 심폐소생술";
  position: absolute;
  left: 0; right: 0; bottom: -34px;
  height: 34px;
  padding: 0 max(20px, calc((100% - var(--wrap)) / 2 + 20px));
  background: #fff;
  border-bottom: 1px solid var(--line);
  color: var(--heart);
  font-size: 13.5px;
  font-weight: 800;
  line-height: 34px;
  letter-spacing: -0.2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
body.site-aed .brand {
  position: relative;
  padding-left: 50px;
  font-weight: 900;
  font-size: 23px;
  letter-spacing: -0.8px;
  line-height: 1.2;
  min-height: 38px;
  display: flex;
  align-items: center;
}
/* 표지 바탕 — 흰 둥근 사각 */
body.site-aed .brand::before {
  content: "";
  position: absolute;
  left: 0; top: 50%;
  width: 38px; height: 38px;
  margin-top: -19px;
  border-radius: 7px;
  background: #fff;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, .35);
}
/* 하트 */
body.site-aed .brand::after {
  content: "";
  position: absolute;
  left: 6px; top: 50%;
  width: 26px; height: 24px;
  margin-top: -11px;
  background: var(--safe);
  clip-path: path("M13 23 C5 17 0 12.5 0 7 C0 3 3 0 7 0 C9.7 0 11.8 1.4 13 3.5 C14.2 1.4 16.3 0 19 0 C23 0 26 3 26 7 C26 12.5 21 17 13 23 Z");
}
/* 번개 — 하트 위 흰 사선 */
body.site-aed .brand a::before {
  content: "";
  position: absolute;
  left: 13px; top: 50%;
  width: 12px; height: 18px;
  margin-top: -9px;
  background: #fff;
  clip-path: polygon(55% 0, 10% 55%, 45% 55%, 30% 100%, 90% 40%, 55% 40%, 80% 0);
  z-index: 1;
}
body.site-aed .brand a { color: #fff; }
body.site-aed .brand a:hover { color: #eafff2; text-decoration: none; }

body.site-aed .site-head nav { gap: 8px; margin-left: auto; }
body.site-aed .site-head nav a {
  padding: 6px 14px;
  border: 2px solid #fff;
  border-radius: 5px;
  background: transparent;
  color: #fff;
  font-weight: 800;
  font-size: 14.5px;
}
body.site-aed .site-head nav a.on,
body.site-aed .site-head nav a:hover {
  background: #fff;
  color: var(--accent-strong);
  text-decoration: none;
}

/* 검색창 */
body.site-aed .site-search input[type="search"] {
  border: 2px solid var(--fg);
  border-radius: 6px;
  background: #fff;
  font-weight: 500;
}
body.site-aed .site-search input[type="search"]:focus { outline: 3px solid var(--accent-soft); border-color: var(--accent); }
body.site-aed .site-search button {
  border-radius: 6px;
  background: var(--fg);
  font-weight: 900;
}
body.site-aed .site-search button:hover { background: var(--accent); }

/* ── 경로·제목 ─────────────────────────────────────────────────────── */
body.site-aed .crumb { font-size: 13px; font-weight: 700; }
body.site-aed .crumb a { color: var(--fg-soft); }
body.site-aed .crumb a::after { content: " → "; color: var(--accent); }
body.site-aed .crumb span { color: var(--accent); }

body.site-aed h1 {
  font-weight: 900;
  font-size: 32px;
  line-height: 1.3;
  letter-spacing: -1px;
  color: var(--fg);
  padding-left: 16px;
  border-left: 8px solid var(--safe);
}
body.site-aed .lead { color: var(--fg-soft); margin: -4px 0 22px; }
body.site-aed .data-date { font-family: var(--mono); font-size: 12.5px; margin: -6px 0 18px; color: var(--muted); }

/* ── 요약표: 설치 위치 표지 ─────────────────────────────────────────── */
body.site-aed .summary {
  border: 3px solid var(--safe);
  border-radius: 8px;
  background: #fff;
  font-size: 15.5px;
}
body.site-aed .summary tr:has(> td:empty) { display: none; }
body.site-aed .summary tr + tr th,
body.site-aed .summary tr + tr td { border-top: 1px solid var(--line); }
body.site-aed .summary th {
  width: 110px;
  background: var(--safe);
  color: #fff;
  font-weight: 800;
  font-size: 13.5px;
}
body.site-aed .summary tr + tr th { border-top-color: rgba(255, 255, 255, .25); }
body.site-aed .summary td { font-weight: 700; }

body.site-aed .btn { border-radius: 6px; font-weight: 800; }
body.site-aed .btn-phone { border: 2px solid var(--fg); color: var(--fg); background: #fff; }
body.site-aed .btn-phone:hover { background: var(--fg); color: #fff; }

/* ── 질답: 응급처치 단계 카드 ──────────────────────────────────────── */
body.site-aed section.qa { counter-reset: ae-q; }
body.site-aed .qa-head {
  font-weight: 900;
  font-size: 20px;
  letter-spacing: -0.6px;
  color: var(--fg);
}
/* 응급 십자 */
body.site-aed .qa-head::before {
  content: "";
  width: 24px; height: 24px;
  border-radius: 5px;
  background:
    linear-gradient(#fff, #fff) 50% 50% / 14px 5px no-repeat,
    linear-gradient(#fff, #fff) 50% 50% / 5px 14px no-repeat,
    var(--safe);
}
body.site-aed .qa-list,
body.site-aed section.qa > .qa-item {
  padding: 0 22px;
  border: 2px solid var(--fg);
  border-radius: 8px;
  background: #fff;
  box-shadow: 6px 6px 0 var(--accent-soft);
}
body.site-aed section.qa > .qa-item + .qa-item { margin-top: 12px; }
body.site-aed .qa-item {
  counter-increment: ae-q;
  position: relative;
  padding: 20px 0 20px 70px;
  border-bottom: 2px solid var(--line-soft);
}
body.site-aed section.qa > .qa-item { padding: 20px 22px 20px 92px; }
body.site-aed .qa-item::before {
  content: "STEP " counter(ae-q);
  position: absolute;
  left: 0; top: 19px;
  width: 56px;
  padding: 5px 0 4px;
  border-radius: 4px;
  background: var(--safe);
  color: #fff;
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 700;
  text-align: center;
  letter-spacing: .5px;
}
body.site-aed section.qa > .qa-item::before { left: 22px; }
body.site-aed .qa-item h2 {
  font-weight: 800;
  font-size: 17.5px;
  letter-spacing: -0.5px;
  color: var(--fg);
}
body.site-aed .qa-item h2::before { content: none; }
body.site-aed .qa-item p {
  padding-left: 12px;
  border-left: 3px solid var(--accent-line);
  color: var(--fg-soft);
  line-height: 1.8;
}

/* ── 지도 ───────────────────────────────────────────────────────────── */
body.site-aed .mapsec-head { font-weight: 900; font-size: 19px; }
body.site-aed .map-canvas,
body.site-aed .pano-canvas { border: 3px solid var(--safe); border-radius: 8px; }
body.site-aed .map-label { font-weight: 800; color: var(--accent); }

/* ── 주변: 가장 가까운 대체 AED ────────────────────────────────────── */
body.site-aed .near { border-top: 0; margin-top: 44px; }
body.site-aed .near-block {
  padding: 2px 20px 18px;
  border-radius: 8px;
  background: #fff;
  border: 2px solid var(--line);
  border-top: 6px solid var(--safe);
}
body.site-aed .near-block + .near-block { margin-top: 18px; }
body.site-aed .near h2 {
  border-left: 0;
  padding-left: 0;
  font-weight: 900;
  font-size: 18px;
  letter-spacing: -0.5px;
}
body.site-aed .near > .near-block > p { padding-left: 0; }
body.site-aed .near ul { padding-left: 0; }
body.site-aed .near li {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 8px;
  padding: 10px 36px 10px 0;
  border-top: 1px solid var(--line-soft);
}
body.site-aed .near li::after,
body.site-aed .place-list li:not(.ad-row)::after {
  content: "→";
  position: absolute;
  right: 4px; top: 50%;
  width: 24px; height: 24px;
  margin-top: -12px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--safe);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
}
body.site-aed .near li a { font-weight: 800; color: var(--fg); }
body.site-aed .near .more { padding-left: 0; font-weight: 700; }
body.site-aed .dist {
  background: var(--safe);
  color: #fff;
  font-family: var(--mono);
  border-radius: 4px;
}

/* ── 목록: 유도 표지 줄 ─────────────────────────────────────────────── */
body.site-aed section.list > h2,
body.site-aed section.children > h2,
body.site-aed section.other-sites > h2 {
  font-weight: 900;
  font-size: 19px;
  letter-spacing: -0.5px;
  color: var(--fg);
  border-bottom: 3px solid var(--fg);
}
body.site-aed .place-list { display: grid; gap: 8px; }
body.site-aed .place-list li:not(.ad-row) {
  position: relative;
  padding: 12px 44px 12px 18px;
  border: 1.5px solid var(--line);
  border-left: 6px solid var(--safe);
  border-radius: 6px;
  background: #fff;
}
body.site-aed .place-list li:not(.ad-row)::after { right: 12px; }
body.site-aed .place-list li:not(.ad-row):hover { border-color: var(--accent-line); border-left-color: var(--accent-strong); background: var(--accent-wash); }
body.site-aed .place-list li > a { color: var(--fg); font-weight: 800; }
body.site-aed .cat:empty { display: none; }
body.site-aed .cat {
  background: var(--bg-soft);
  color: var(--accent-strong);
  border: 1px solid var(--accent-line);
  border-radius: 4px;
  font-weight: 700;
}

/* 지역·조건·다른 사이트 링크: 초록 표지판 칩 */
body.site-aed .region-links { gap: 8px; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
body.site-aed .region-links li {
  padding: 10px 12px;
  border: 0;
  border-radius: 6px;
  background: var(--safe);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .5), 0 0 0 1px var(--safe);
  flex-wrap: wrap;
  min-width: 0;
}
body.site-aed .region-links li:hover { background: var(--accent-strong); }
body.site-aed .region-links li > a { color: #fff; font-weight: 800; }
body.site-aed .region-links li > a::before { content: "→ "; }
body.site-aed .region-links .count { color: #d6f5e3; font-family: var(--mono); font-size: 11.5px; }
body.site-aed .count { font-family: var(--mono); }

/* 홈 메뉴 */
body.site-aed .menu-cards li {
  padding: 22px 22px;
  border: 3px solid var(--safe);
  border-radius: 8px;
  background: #fff;
  box-shadow: 6px 6px 0 var(--accent-soft);
}
body.site-aed .menu-cards li:hover { background: var(--accent-wash); }
body.site-aed .menu-cards li > a { color: var(--fg); font-weight: 900; font-size: 20px; letter-spacing: -0.6px; }

/* ── 출처·삭제요청·푸터 ─────────────────────────────────────────────── */
body.site-aed .source h2 { font-weight: 900; letter-spacing: -0.5px; }
body.site-aed .removal {
  border: 2px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
}
body.site-aed .removal::before { background: var(--accent-soft); opacity: .5; }
body.site-aed .removal-icon { border-radius: 6px; background: var(--fg); color: #fff; }
body.site-aed .removal-title { font-weight: 900; }
body.site-aed .btn-removal { background: var(--fg); border-radius: 6px; box-shadow: none; }
body.site-aed .btn-removal:hover { background: var(--accent); box-shadow: none; }
body.site-aed .site-foot {
  margin-top: 56px;
  padding: 22px 20px 44px;
  border-top: 6px solid var(--safe);
  color: var(--fg-soft);
  font-size: 13.5px;
}

/* ── 모바일 ─────────────────────────────────────────────────────────── */
@media (max-width: 600px) {
  body.site-aed .site-head { padding: 14px 16px; margin-bottom: 44px; }
  body.site-aed .site-head::after { padding: 0 16px; font-size: 12px; }
  body.site-aed .site-head nav { margin-left: 0; }
  body.site-aed .brand { font-size: 20px; }
  body.site-aed h1 { font-size: 25px; padding-left: 12px; border-left-width: 6px; }
  body.site-aed .summary th { width: 84px; }
  body.site-aed .qa-list { padding: 0 14px; }
  body.site-aed .qa-item { padding: 50px 0 18px; }
  body.site-aed .qa-item::before { top: 18px; }
  body.site-aed section.qa > .qa-item { padding: 50px 14px 16px; }
  body.site-aed section.qa > .qa-item::before { left: 14px; }
  body.site-aed .near-block { padding: 2px 14px 16px; }
  body.site-aed .region-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ── 다크 모드: 야간 유도등(어둠 속 초록 발광) ─────────────────────── */
@media (prefers-color-scheme: dark) {
  body.site-aed {
    --fg: #eaf2ed;
    --fg-soft: #bfcdc4;
    --muted: #8c9b92;
    --line: #2f3a34;
    --line-soft: #26302a;
    --bg: #131815;
    --bg-soft: #1b221e;
    --accent: #3fd488;
    --accent-strong: #7be6ad;
    --accent-soft: #163a27;
    --accent-wash: #15241b;
    --accent-line: #2b6445;
    --safe: #0f8f55;
    --heart: #ff6b7d;
    background: #0e1210;
  }
  body.site-aed .site-head::after { background: #161c19; }
  body.site-aed .summary,
  body.site-aed .qa-list,
  body.site-aed section.qa > .qa-item,
  body.site-aed .near-block,
  body.site-aed .place-list li:not(.ad-row),
  body.site-aed .menu-cards li,
  body.site-aed .removal,
  body.site-aed .site-search input[type="search"],
  body.site-aed .btn-phone { background: #161c19; }
  body.site-aed .qa-list,
  body.site-aed section.qa > .qa-item { border-color: #3a4a41; }
  body.site-aed .site-search button,
  body.site-aed .btn-removal,
  body.site-aed .removal-icon { background: var(--safe); color: #fff; }
  body.site-aed .btn-phone:hover { background: var(--fg); color: #131815; }
  body.site-aed .site-head nav a.on,
  body.site-aed .site-head nav a:hover { color: #0b4a2a; }
}
