/* static/css/agreeOfTerms.css */

/* ===== Design tokens ===== */
:root {
  --bg: #f7fafc;
  --panel: #ffffff;
  --text: #1f2937;
  --muted: #6b7280;
  --border: #e5e7eb;

  --primary: #004c63;        /* 헤더/강조 컬러 */
  --primary-contrast: #fdfdfd;
  --primary-hover: #03607d;

  --btn-bg: #9c5d42;         /* 약관 보기 버튼 컬러 */
  --btn-bg-hover: #b06c4f;
  --btn-fg: #ffffe4;

  --radius: 12px;
  --shadow: 0 8px 24px rgba(0,0,0,.06);
}

/* ===== Base reset ===== */
*,
*::before,
*::after { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial,
               "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
#top {margin: 10px 10px 10px 10px;
    padding:30px 0px;
    background-color:#004c63;

    color:#F7FAFC;
    text-align: center}

#title {font-size: 28px;margin:0px 0px;}

/* ===== Layout ===== */
#container { padding: 24px; }
#wrapper  { max-width: 960px; margin: 0 auto; }
#calc {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px;
}

/* ===== Typography ===== */
#page_title,
h2#page_title {
  margin: 0 0 20px 0;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--primary);
}

/* ===== Blocks ===== */
.terms-block {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  padding: 14px 0;
  border-top: 1px solid var(--border);
}

.terms-block:first-of-type {
  border-top: 0;
}

/* 라벨 및 체크박스 */
.terms-block label,
#agree_all_block label {
  user-select: none;
  cursor: pointer;
  color: var(--text);
}

.agreement,
#agreeAll {
  width: 18px;
  height: 18px;
  vertical-align: middle;
  accent-color: var(--primary); /* 체크박스 색 */
  margin-right: 6px;
}

/* ===== Buttons ===== */
button {
  appearance: none;
  border: 1px solid transparent;
  background: var(--btn-bg);
  color: var(--btn-fg);
  padding: 8px 14px;
  font-size: 14px;
  border-radius: 10px;
  line-height: 1.2;
  cursor: pointer;
  transition: transform .05s ease, background .15s ease;
  box-shadow: 0 1px 0 rgba(0,0,0,.15);
  min-width: 180px;   /* ✅ 버튼 최소 크기 통일 */
  text-align: center; /* 글씨 가운데 정렬 */
}


button:hover { background: var(--btn-bg-hover); }
button:active { transform: translateY(1px); }

button:focus-visible {
  outline: 3px solid rgba(0, 76, 99, .35);
  outline-offset: 2px;
}

/* 확인 버튼(주색 계열로 강조) */
#confirm_section { margin-top: 6px; display: flex; justify-content: flex-end; }
#confirmBtn {
  background: var(--primary);
  color: var(--primary-contrast);
  padding: 10px 16px;
  font-weight: 700;
}

#confirmBtn:hover { background: var(--primary-hover); }

#confirmBtn[disabled] {
  opacity: .55;
  cursor: not-allowed;
  filter: grayscale(.15);
}

/* ===== Utility spacing (불필요한 br 대신 margin으로 제어 권장) ===== */
#terms1_br,
#terms2_br,
#agree_all_br {
  display: none; /* 구조상 존재하지만 레이아웃은 margin으로 관리 */
}

/* ===== Footer (선택) ===== */
#bottom {
  margin: 24px 0 0;
  padding: 14px;
  text-align: center;
  color: var(--primary-contrast);
  background: var(--primary);
  border-radius: var(--radius);
}

/* ===== Responsive ===== */
@media (max-width: 720px) {
  #container { padding: 16px; }
  #calc { padding: 20px; }

  #page_title,
  h2#page_title { font-size: 20px; }

  .terms-block {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  button { width: 100%; }
  #confirm_section { justify-content: stretch; }
  #confirmBtn { width: 100%; }
}

#bottom {
    margin: 10px;
    padding: 10px 0;
    color:#F7FAFC;
    background-color:#004c63;
    text-align: center;
}

/* ===== Motion preference ===== */
@media (prefers-reduced-motion: reduce) {
  button { transition: none; }
}
