/* ============================================================
   DESIGN SYSTEM — TimeTracker
   팔레트: 라벤더 → 크림 그라데이션 (로고/배경 이미지 톤)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+KR:wght@400;500;700;900&display=swap');

:root {
  /* ── 컬러 팔레트 (배경 이미지 톤) ─────────────────────── */
  --color-bg:           #F0ECF8;   /* 연한 라벤더 */
  --color-bg-card:      #FDFBFA;   /* 밝은 크림 카드 */
  --color-bg-subtle:    #E8E4F5;   /* 라벤더 톤 */
  --color-bg-dark:      #2C3E50;   /* 다크 블루그레이 — 헤더 */
  --color-bg-dark-2:    #3D5A80;   /* 조금 밝은 네이비 */

  --color-text:         #2C3E50;   /* 다크 그레이 */
  --color-text-inverse: #F8F6F2;   /* 밝은 배경 위 텍스트 */
  --color-text-muted:   #5A6578;   /* 뮤트 */
  --color-text-faint:   #9CA3AF;   /* 연한 텍스트 */

  --color-border:       #E2DEE9;   /* 연한 보더 */
  --color-border-dark:  #3A4A5C;   /* 다크 보더 */
  --color-border-rule:  #D4CFE0;   /* 구분선 */

  /* 포인트: 아이콘 블루그레이 */
  --color-primary:      #3D6A8A;   /* 차분한 블루 */
  --color-primary-hover:#2D5A7A;
  --color-primary-light:#E8F0F8;
  --color-primary-text: #FFFFFF;

  /* 보조 포인트 */
  --color-accent-yellow:#E8D48B;   /* 크림 톤 액센트 */
  --color-accent-green: #4A7C59;
  --color-accent-blue:  #5B8FB9;   /* 로고 블루 */
  --color-accent-ink:    #2C3E50;

  /* 상태 */
  --color-success:      #4A7C59;
  --color-success-light:#EBF4EE;
  --color-warning:      #E8B84B;
  --color-warning-light:#FEF9ED;
  --color-danger:       #C0392B;
  --color-danger-light: #FCF0EE;

  /* ── 타이포그래피 ──────────────────────────────────────── */
  --font-family:        'Noto Sans KR', -apple-system, sans-serif;

  --font-size-xs:   0.6875rem; /* 11px */
  --font-size-sm:   0.8125rem; /* 13px */
  --font-size-base: 0.9375rem; /* 15px */
  --font-size-md:   1rem;      /* 16px */
  --font-size-lg:   1.125rem;  /* 18px */
  --font-size-xl:   1.375rem;  /* 22px */
  --font-size-2xl:  1.75rem;   /* 28px */
  --font-size-3xl:  2.5rem;    /* 40px */
  --font-size-timer:4rem;      /* 64px */

  --font-weight-normal:   400;
  --font-weight-medium:   500;
  --font-weight-bold:     700;
  --font-weight-black:    900;

  /* ── Spacing (8px grid) ──────────────────────────────── */
  --space-1:  0.25rem;
  --space-2:  0.5rem;
  --space-3:  0.75rem;
  --space-4:  1rem;
  --space-5:  1.25rem;
  --space-6:  1.5rem;
  --space-8:  2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;

  /* ── Radii ───────────────────────────────────────────── */
  --radius-sm:   0.25rem;  /* 4px  — 날카롭고 단호한 느낌 */
  --radius-md:   0.375rem; /* 6px  */
  --radius-lg:   0.5rem;   /* 8px  */
  --radius-xl:   0.75rem;  /* 12px */
  --radius-2xl:  1rem;     /* 16px */
  --radius-full: 9999px;

  /* ── Shadows ─────────────────────────────────────────── */
  --shadow-stamp: 2px 2px 0px rgba(0,0,0,0.12);       /* 도장 눌린 느낌 */
  --shadow-card:  0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-lifted:0 4px 12px rgba(0,0,0,0.08);

  /* ── Transitions ─────────────────────────────────────── */
  --transition-fast: 100ms ease;
  --transition-base: 180ms ease;
  --transition-slow: 280ms ease;

  /* ── Layout ──────────────────────────────────────────── */
  --app-max-width:      448px;
  --header-height:      56px;
  --bottom-nav-height:  60px;

}

/* ── Reset ───────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { height: 100%; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  line-height: 1.6;
  color: var(--color-text);
  background: linear-gradient(180deg, #E8E4F5 0%, #F5F2E8 50%, #F8F5EB 100%);
  background-attachment: fixed;
  min-height: 100%;
  height: 100%;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

#app {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: transparent;
}

/* ── App Shell ───────────────────────────────────────────── */
.app-shell {
  width: 100%;
  max-width: var(--app-max-width);
  height: 100%;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, rgba(232,228,245,0.92) 0%, rgba(245,242,232,0.95) 100%);
  position: relative;
  overflow: hidden;
  box-shadow: 0 0 0 1px var(--color-border), var(--shadow-lifted);
}

/* ── Screen ──────────────────────────────────────────────── */
.screen { flex: 1; display: flex; flex-direction: column; overflow: hidden; }

.screen-content {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-y: contain;
  scrollbar-width: none;
}
.screen-content::-webkit-scrollbar { display: none; }

@keyframes screenIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
.screen { animation: screenIn var(--transition-base) ease; }

/* ── Focus Ring ──────────────────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
  border-radius: var(--radius-md);
}

/* ── Typography ──────────────────────────────────────────── */
.t-display {
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-black);
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.t-title {
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-bold);
  line-height: 1.3;
}

.t-body {
  font-size: var(--font-size-sm);
  line-height: 1.65;
}

.t-caption {
  font-size: var(--font-size-xs);
  color: var(--color-text-muted);
  line-height: 1.5;
}

.t-label {
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-bold);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
}

/* ── 도장 스탬프 스타일 텍스트 ──────────────────────────── */
.stamp-text {
  display: inline-block;
  border: 2.5px solid var(--color-primary);
  color: var(--color-primary);
  font-weight: var(--font-weight-black);
  font-size: var(--font-size-xs);
  letter-spacing: 0.06em;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  line-height: 1.4;
  transform: rotate(-1deg);
}

/* 유틸 */
.sr-only { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0,0,0,0); }
button { cursor: pointer; font-family: inherit; }
input, textarea, select { font-family: inherit; }
a { color: var(--color-primary); text-decoration: none; }

/* ── 로그인 화면 (단순 그라데이션 배경 + 로고) ───────────────── */
.login-screen {
  width: 100%;
  max-width: var(--app-max-width);
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: var(--space-6);
}

.login-screen__bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, #E8E4F5 0%, #F5F2E8 60%, #F8F5EB 100%);
  z-index: -1;
}

.login-screen__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 280px;
}

.login-screen__brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: var(--space-8);
}

.login-screen__logo {
  width: 100%;
  max-width: 160px;
  height: auto;
  object-fit: contain;
  display: block;
}

.login-screen__logo-fallback {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  color: var(--color-text);
}
.login-screen__logo-fallback svg {
  color: var(--color-primary);
}
.login-screen__logo-fallback span {
  font-size: var(--font-size-lg);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.login-form {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.login-screen__demo {
  font-size: var(--font-size-xs);
  color: var(--color-text-muted);
  margin-top: var(--space-4);
}
