/* 제작 요청(/request). 바탕·글자·상단 바·바닥은 /blog/blog.css 를 그대로 쓰고, 여기는 폼·포트폴리오·작은 글씨만 둔다.
   순서: 제목·소개 → 폼 → 지금까지 만든 것 → 고르는 기준·진행 조건(작은 글씨). 데스크톱(721px~)은 연락처 칸을 두 칸씩 나란히.
   색은 blog.css 변수만 쓴다. 블루(--glow)는 제출 버튼 한 곳과 포커스 테두리·밑줄에만. */

.req {
  --req-r: 10px; /* 입력칸·동의 상자·포트폴리오 그림 반경 */
  --req-gap: 24px; /* 칸 사이 */
  --req-err: #ff8a80; /* check-allow: B1 blog.css 에 오류 색 변수가 없어 여기서 한 번만 정의(검정 바탕 대비 7.9:1) */
}

/* hidden 속성이 아래 display:grid 등에 덮이지 않게(보낸 뒤·마감 뒤 폼 숨기기) */
.req [hidden] {
  display: none !important;
}

.req .index-head h1 {
  font-size: clamp(30px, 5vw, 44px);
}
.req-period {
  display: inline-block;
  font-size: 0.42em;
  font-weight: 600;
  letter-spacing: 0;
  vertical-align: middle;
  color: var(--ink-3);
}

/* 폼 */
.req-form {
  display: grid;
  gap: var(--req-gap);
  margin-top: 8px;
}
.req-row {
  display: grid;
  gap: var(--req-gap);
}
.req-field {
  display: grid;
  gap: 8px;
}
.req-field label {
  font-size: 15px;
  font-weight: 650;
  color: var(--ink);
}
.req-sub {
  margin-left: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-3);
}
.req-field input,
.req-field textarea {
  width: 100%;
  padding: 12px 16px;
  font: inherit;
  font-size: 17px; /* iOS 확대 방지(16 이상) */
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg-2);
  border: 1px solid var(--line-2);
  border-radius: var(--req-r);
  transition: border-color 0.15s ease;
}
.req-field input {
  height: 52px;
}
.req-field textarea {
  min-height: 176px;
  resize: vertical;
}
.req-field input::placeholder,
.req-field textarea::placeholder {
  color: var(--ink-3);
}
.req-field input:hover,
.req-field textarea:hover {
  border-color: rgba(255, 255, 255, 0.32); /* check-allow: B1 blog.css 선 굵기 단계(0.09·0.17) 위 호버 한 단계 */
}
.req-field input:focus-visible,
.req-field textarea:focus-visible {
  outline: 2px solid var(--glow-text);
  outline-offset: 2px;
  border-radius: var(--req-r);
}
.req-field [aria-invalid="true"] {
  border-color: var(--req-err);
}
.req-err {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--req-err);
}

/* 개인정보 수집·이용 동의: 접어 두는 칸 */
.req-consent {
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink-3);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.req-consent summary {
  display: flex;
  align-items: center;
  min-height: 44px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-2);
  cursor: pointer;
  list-style: none;
}
.req-consent summary::-webkit-details-marker {
  display: none;
}
.req-consent summary::after {
  content: "";
  width: 8px;
  height: 8px;
  margin-left: auto;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  transition: transform 0.15s ease;
}
.req-consent[open] summary::after {
  transform: rotate(-135deg) translateY(-2px);
}
.req-consent dl {
  display: grid;
  gap: 4px;
  margin: 0;
}
.req-consent dl div {
  display: grid;
  grid-template-columns: 3.5em 1fr;
  gap: 8px;
}
.req-consent dd {
  margin: 0;
  color: var(--ink-2);
}
.req-consent p {
  margin: 8px 0 16px;
}
.req-consent a {
  color: var(--ink-2);
  text-decoration: underline;
  text-decoration-color: var(--glow-text);
  text-underline-offset: 3px;
}

/* 사람에게 안 보이는 허니팟 칸 */
.req-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.req-send {
  justify-self: stretch;
  min-height: 52px;
  padding: 0 24px;
  font: inherit;
  font-size: 16px;
  font-weight: 700;
  color: #fbfbfa; /* check-allow: B1 blog.css .cta-btn 과 같은 버튼 글자색(블루 위 대비 4.9:1) */
  background: var(--glow);
  border: 0;
  border-radius: var(--req-r);
  cursor: pointer;
  transition: background-color 0.2s ease;
}
.req-send:hover {
  background: #2457e6; /* check-allow: B1 blog.css .cta-btn:hover 와 같은 값 */
}
.req-send:disabled {
  opacity: 0.6;
  cursor: progress;
}
.req-status {
  margin: -8px 0 0;
  min-height: 1.6em;
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-2);
}
.req-status.is-error {
  color: var(--req-err);
}
.req-status a {
  color: inherit;
}

/* 보낸 뒤·마감 뒤 */
.req-done {
  margin-top: 8px;
  padding: 24px 0;
}
.req-done:focus {
  outline: none;
}
.req-done h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.4;
}
.req-done p {
  margin: 8px 0 0;
  color: var(--ink-2);
}

/* 지금까지 만든 것: 2열 카드. GIF 는 2:1 */
.req-works {
  margin-top: 64px;
  padding-top: 24px;
  border-top: 1px solid var(--line-2);
}
.req-works h2 {
  margin: 0 0 16px;
  font-size: 18px;
  line-height: 1.4;
}
.req-works ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.req-work a {
  display: grid;
  gap: 4px;
  text-decoration: none;
}
.req-work img {
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 1;
  object-fit: cover;
  margin-bottom: 8px;
  background: var(--bg-2);
  border-radius: var(--req-r);
}
.req-work-t {
  font-size: 15px;
  font-weight: 650;
  line-height: 1.45;
  color: var(--ink);
}
.req-work-k {
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink-3);
}
.req-work a:hover .req-work-t {
  text-decoration: underline;
  text-decoration-color: var(--glow-text);
  text-underline-offset: 3px;
}
.req-more {
  margin: 16px 0 0;
  font-size: 14px;
}
.req-more a {
  color: var(--ink-2);
  text-decoration: underline;
  text-decoration-color: var(--glow-text);
  text-underline-offset: 3px;
}

/* 작은 글씨: 고르는 기준·진행 조건 */
.req-fine {
  margin-top: 48px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  line-height: 1.6;
  color: var(--ink-3);
}
.req-fine h2 {
  margin: 12px 0 4px;
  font-size: 12px;
  font-weight: 650;
  color: var(--ink-2);
}
.req-fine h2:first-child {
  margin-top: 0;
}
.req-fine p,
.req-fine ol,
.req-fine ul {
  margin: 0;
}
.req-fine ol,
.req-fine ul {
  padding-left: 1.4em;
}

@media (min-width: 721px) {
  .req-row {
    grid-template-columns: 1fr 1fr;
  }
  .req-send {
    justify-self: start;
    min-width: 200px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .req-field input,
  .req-field textarea,
  .req-consent summary::after,
  .req-send {
    transition: none;
  }
}
