/*
 * Scope - 기본 토큰 및 베이스 스타일
 * Studio_bada 비주얼 프레임워크(divetobada.com) 기준
 */

@import url("https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/variable/pretendardvariable.min.css");

:root {
  --background: #f0f2f5;
  --card: #ffffff;
  --foreground: #09090b;
  --muted: #71717a;
  --border: #e4e4e7;
  --primary: #18181b;
  --primary-hover: #2d2d2d;
  --link: #3b82f6;
  --danger: #dc2626;
  --accent: #9333ea;
  --radius: 0.5rem;
  --canvas-bg: #e5e5e5;
  --sidebar-w: 260px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  background-color: var(--background);
  color: var(--foreground);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--link);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

h1,
h2,
h3 {
  margin: 0;
  font-weight: 700;
  color: var(--foreground);
}

.page-wrapper {
  max-width: 960px;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
}

.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background-color: var(--card);
  border-bottom: 1px solid var(--border);
}

.app-header .brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--foreground);
}

.brand-mark {
  display: block;
  height: 26px;
  width: auto;
  border-radius: 6px;
}

.app-header .brand:hover {
  text-decoration: none;
}

.app-header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.app-header-user {
  font-size: 0.875rem;
  color: var(--muted);
}

/* 폼 입력 (디자인 시스템: 2px solid #000, radius 6px) */
.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  margin-bottom: 1rem;
}

/* display:flex가 기본 [hidden] 규칙을 덮어쓰므로, 숨김 속성이 우선하도록 보정 */
.form-field[hidden] {
  display: none;
}

.form-field label {
  font-size: 0.875rem;
  font-weight: 600;
}

.form-input,
.form-textarea {
  width: 100%;
  border: 2px solid #000;
  border-radius: 6px;
  padding: 0.75rem;
  font-size: 14px;
  font-family: inherit;
  background-color: #fff;
}

.form-textarea {
  min-height: 96px;
  resize: vertical;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--primary);
}

/* 셀렉트 (브라우저 기본 스타일 금지 - 프로젝트 정의 스타일 사용) */
.form-select {
  width: 100%;
  border: 2px solid #000;
  border-radius: 6px;
  padding: 0.75rem 2.25rem 0.75rem 0.75rem;
  font-size: 14px;
  font-family: inherit;
  background-color: #fff;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23000' d='M6 8 0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
}

.form-select:focus {
  outline: none;
  border-color: var(--primary);
}
