/* ===========================
   상담 신청 페이지 스타일
   v1.20.4
   =========================== */

/* 컨테이너 */
.consult-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
  background: var(--bg, #f9fafb);
  min-height: 100vh;
}

/* 헤더 */
.consult-header {
  text-align: center;
  padding: 40px 20px;
  background: #2196F3;
  border-radius: 16px;
  color: white;
  margin-bottom: 30px;
  box-shadow: 0 2px 8px rgba(33, 150, 243, 0.15);
}

.consult-header h1 {
  font-size: 28px;
  font-weight: 700;
  margin: 0 0 8px 0;
  color: white;
}

.consult-header .subtitle {
  font-size: 14px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.9);
  margin: 0;
  letter-spacing: 0.3px;
}

/* 공지사항 섹션 제거됨 (v1.20.3) */

/* 양식 섹션 */
.form-section {
  background: white;
  border-radius: 12px;
  padding: 32px 24px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.form-section h3 {
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 24px 0;
  color: #1f2937;
}

/* 추천인 정보 */
.referrer-info {
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  border: 2px solid #f59e0b;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 24px;
}

.referrer-info .icon {
  font-size: 24px;
}

.referrer-info .text {
  font-size: 15px;
  color: #78350f;
  line-height: 1.5;
}

.referrer-info strong {
  color: #b45309;
  font-weight: 700;
}

/* 폼 그룹 */
.form-group {
  margin-bottom: 24px;
}

.form-group.required label::after {
  content: ' *';
  color: #ef4444;
}

.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 8px;
}

.form-group label .required {
  color: #ef4444;
  font-weight: 700;
}

.form-group input[type="text"],
.form-group input[type="tel"],
.form-group input[type="email"],
.form-group input[type="date"],
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 15px;
  transition: all 0.2s;
  box-sizing: border-box;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.form-group small {
  display: block;
  margin-top: 6px;
  font-size: 13px;
  color: #6b7280;
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
  font-family: inherit;
}

/* 선택 항목 */
.optional-fields {
  margin-top: 32px;
  padding-top: 32px;
  border-top: 2px solid #e5e7eb;
}

.optional-fields h4 {
  font-size: 16px;
  font-weight: 600;
  color: #6b7280;
  margin: 0 0 20px 0;
}

/* 체크박스 그룹 */
.checkbox-group {
  background: #f9fafb;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  padding: 16px;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
  color: #1f2937;
}

.checkbox-label input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  cursor: pointer;
  flex-shrink: 0;
}

.privacy-details {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #e5e7eb;
}

.privacy-details p {
  font-size: 13px;
  color: #6b7280;
  margin: 0;
  line-height: 1.6;
}

.privacy-details strong {
  color: #374151;
  font-weight: 600;
}

/* 제출 버튼 */
.btn-submit {
  width: 100%;
  padding: 16px;
  background: #2196F3;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 2px 8px rgba(33, 150, 243, 0.3);
}

.btn-submit:hover {
  background: #1976D2;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(33, 150, 243, 0.4);
}

.btn-submit:active {
  transform: translateY(0);
  background: #1565C0;
}

.note {
  text-align: center;
  font-size: 13px;
  color: #6b7280;
  margin-top: 16px;
  font-weight: 500;
}

/* 성별 선택 */
.gender-select {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

.gender-option {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  background: white;
  min-width: 60px;
}

.gender-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.gender-option span {
  font-size: 15px;
  font-weight: 600;
  color: #6b7280;
  transition: color 0.2s;
}

.gender-option:hover {
  border-color: #2196F3;
  background: #f0f9ff;
}

.gender-option input[type="radio"]:checked + span {
  color: #2196F3;
}

.gender-option:has(input[type="radio"]:checked) {
  border-color: #2196F3;
  background: #E3F2FD;
}

/* 완료 화면 */
.success-section {
  background: white;
  border-radius: 12px;
  padding: 60px 24px;
  text-align: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.success-icon {
  font-size: 80px;
  margin-bottom: 24px;
  animation: scaleIn 0.5s ease-out;
}

@keyframes scaleIn {
  from {
    transform: scale(0);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.success-section h2 {
  font-size: 24px;
  font-weight: 700;
  color: #1f2937;
  margin: 0 0 16px 0;
}

.success-message {
  font-size: 16px;
  color: #6b7280;
  line-height: 1.6;
  margin: 0 0 32px 0;
}

.contact-info {
  background: #f9fafb;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 32px;
}

.contact-info p {
  font-size: 14px;
  color: #6b7280;
  margin: 0 0 8px 0;
}

.phone-link {
  display: inline-block;
  font-size: 24px;
  font-weight: 700;
  color: #6366f1;
  text-decoration: none;
  transition: color 0.2s;
}

.phone-link:hover {
  color: #4f46e5;
}

/* 유튜브 버튼 */
.btn-home {
  padding: 14px 32px;
  background: #FF0000;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-home::before {
  content: "▶";
  font-size: 14px;
}

.btn-home:hover {
  background: #CC0000;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(255, 0, 0, 0.3);
}

/* 푸터 */
.consult-footer {
  text-align: center;
  padding: 40px 20px;
  color: #9ca3af;
  font-size: 14px;
  margin-top: 40px;
}

.consult-footer p {
  margin: 8px 0;
}

/* 반응형 */
@media (max-width: 768px) {
  .consult-container {
    padding: 12px;
  }

  .consult-header {
    padding: 32px 16px;
    border-radius: 12px;
  }

  .consult-header h1 {
    font-size: 24px;
  }

  .consult-header .subtitle {
    font-size: 12px;
  }

  .notice-section,
  .form-section,
  .success-section {
    padding: 20px 16px;
  }

  .success-icon {
    font-size: 60px;
  }

  .success-section h2 {
    font-size: 20px;
  }

  .phone-link {
    font-size: 20px;
  }
}

/* ===== 홈 공지 카드 (앱과 동일) ===== */
.home-notice-card {
  background: var(--white, #fff);
  border-radius: 12px;
  border: 1.5px solid #2196F3;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(33,150,243,0.10);
}
.home-notice-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: #2196F3;
}
.home-notice-card-label {
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.3px;
}
.home-notice-card-more {
  font-size: 11px;
  color: rgba(255,255,255,0.85);
  font-weight: 600;
  cursor: pointer;
}
.home-notice-card-body { background: #fff; }

.home-notice-row {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 12px;
  cursor: pointer;
  transition: background 0.12s;
  background: #fff;
  border-bottom: none;
}
.home-notice-row.bordered { border-bottom: none; }
.home-notice-row:active { background: #E3F2FD; }
.home-notice-row.pinned { background: #f0f7ff; }
.home-notice-row.pinned.bordered { border-bottom: none; }

.home-notice-badge {
  font-size: 12px;
  flex-shrink: 0;
  opacity: 0.75;
}
.home-notice-title {
  flex: 1;
  font-size: 13px;
  font-weight: 500;
  color: #1f2937;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.home-notice-row.pinned .home-notice-title {
  font-weight: 700;
  color: #1565C0;
}
.home-notice-date {
  font-size: 11px;
  color: #9ca3af;
  flex-shrink: 0;
  white-space: nowrap;
}
.home-notice-arrow {
  font-size: 14px;
  color: #90CAF9;
  flex-shrink: 0;
  margin-left: 1px;
}

/* ===== 서브 화면 ===== */
.sub-screen {
  display: none;
  position: fixed;
  inset: 0;
  background: #f9fafb;
  z-index: 1000;
  max-width: 800px;
  margin: 0 auto;
  overflow-y: auto;
}

.sub-screen.open {
  display: block;
}

.sub-header {
  background: linear-gradient(135deg, #2196F3 0%, #1976D2 100%);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  border-bottom: none;
  position: sticky;
  top: 0;
  z-index: 10;
  box-shadow: 0 2px 12px rgba(33,150,243,0.3);
}

.sub-back-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 700;
  color: white;
  flex-shrink: 0;
  transition: all 0.2s;
  border: none;
  cursor: pointer;
}

.sub-back-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: scale(1.05);
}

.sub-header-title {
  font-size: 17px;
  font-weight: 700;
  color: white;
  text-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.sub-body {
  padding: 20px 16px;
  padding-bottom: 40px;
}

/* ===== 공지 목록 ===== */
.notice-item {
  background: #fff;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
  padding: 14px 16px;
  cursor: pointer;
  margin-bottom: 8px;
  transition: all 0.2s;
}

.notice-item:hover {
  background: #f9fafb;
  border-color: #2196F3;
}

.notice-item-top {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.notice-item-title {
  flex: 1;
  font-size: 14px;
  font-weight: 600;
  color: #1f2937;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notice-pinned-badge {
  background: #2196F3;
  color: white;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 700;
}

.notice-item-date {
  font-size: 12px;
  color: #9ca3af;
}

/* ===== 공지 상세 ===== */
.notice-detail-title {
  font-size: 18px;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 8px;
}

.notice-detail-meta {
  font-size: 13px;
  color: #9ca3af;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #e5e7eb;
}

.notice-detail-content {
  font-size: 15px;
  color: #1f2937;
  line-height: 1.75;
  word-break: break-word;
}

.notice-detail-content p { margin: 0 0 8px 0; }
.notice-detail-content h1 { font-size: 1.5em; font-weight: 700; margin: 16px 0 8px; }
.notice-detail-content h2 { font-size: 1.3em; font-weight: 700; margin: 14px 0 6px; }
.notice-detail-content h3 { font-size: 1.1em; font-weight: 700; margin: 12px 0 6px; }
.notice-detail-content strong { font-weight: 700; }
.notice-detail-content em { font-style: italic; }
.notice-detail-content u { text-decoration: underline; }
.notice-detail-content a { color: #2196F3; text-decoration: underline; }
.notice-detail-content ul, .notice-detail-content ol { padding-left: 24px; margin: 8px 0; }
.notice-detail-content li { margin: 4px 0; }
.notice-detail-content img { max-width: 100%; border-radius: 10px; margin: 8px 0; display: block; }

.notice-video-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 10px;
  overflow: hidden;
  background: #000;
  margin: 12px 0;
  display: block;
}
.notice-video-wrap iframe,
.notice-video-wrap video {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: none;
  display: block;
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
}

.empty-state-icon {
  font-size: 48px;
  margin-bottom: 16px;
}

.empty-state-text {
  font-size: 15px;
  color: #9ca3af;
}
