@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/static/pretendard.css');

:root {
  --primary:       #1A56A0;
  --primary-light: #E8F4FD;
  --holiday-red:   #E53E3E;
  --text-main:     #1A202C;
  --text-sub:      #718096;
  --bg:            #F7FAFC;
  --white:         #FFFFFF;
  --border:        #E2E8F0;
  --radius:        12px;
  --shadow:        0 2px 8px rgba(0,0,0,0.07);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Pretendard', 'Noto Sans KR', -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text-main);
  line-height: 1.6;
  font-size: 16px;
}

a { color: inherit; text-decoration: none; }

/* ── Navigation ── */
.nav {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  align-items: center;
  height: 56px;
  gap: 20px;
}

.nav-logo {
  font-size: 17px;
  font-weight: 800;
  color: var(--primary);
  white-space: nowrap;
  letter-spacing: -0.3px;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2px;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav-links::-webkit-scrollbar { display: none; }

.nav-links a {
  display: block;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  color: var(--text-sub);
  transition: background 0.15s, color 0.15s;
}
.nav-links a:hover,
.nav-links a.active {
  background: var(--primary-light);
  color: var(--primary);
  font-weight: 600;
}

/* ── Container ── */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 28px 16px 48px;
}

/* ── Hero ── */
.hero {
  background: linear-gradient(135deg, #1A56A0, #2563EB);
  color: var(--white);
  padding: 36px 16px;
  text-align: center;
}
.hero h1 {
  font-size: clamp(20px, 4vw, 30px);
  font-weight: 800;
  margin-bottom: 8px;
  letter-spacing: -0.5px;
}
.hero p { font-size: 15px; opacity: 0.85; }

/* ── Page title ── */
.page-header {
  margin-bottom: 24px;
}
.page-header h1 {
  font-size: clamp(20px, 3.5vw, 26px);
  font-weight: 800;
  margin-bottom: 6px;
  letter-spacing: -0.5px;
}
.page-header p { color: var(--text-sub); font-size: 15px; }

/* ── Ad slots ── */
.ad-slot {
  background: #f0f0f0;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #bbb;
  font-size: 12px;
  margin: 16px 0;
}
.ad-top    { min-height: 90px; }
.ad-mid    { min-height: 250px; }
.ad-bottom { min-height: 90px; }

/* ── Year navigation ── */
.year-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
}
.year-nav-btn {
  width: 36px;
  height: 36px;
  border: 2px solid var(--border);
  background: var(--white);
  border-radius: 8px;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-sub);
  transition: all 0.15s;
  font-family: inherit;
}
.year-nav-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}
.year-input {
  width: 88px;
  text-align: center;
  font-size: 18px;
  font-weight: 800;
  padding: 6px 4px;
  border: 2px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
  color: var(--text-main);
  background: var(--white);
  -moz-appearance: textfield;
}
.year-input:focus { outline: none; border-color: var(--primary); }
.year-input::-webkit-inner-spin-button,
.year-input::-webkit-outer-spin-button { -webkit-appearance: none; }

/* ── Summary cards ── */
.summary-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.summary-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  flex: 1;
  min-width: 120px;
  box-shadow: var(--shadow);
}
.summary-card .num {
  font-size: 30px;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.1;
}
.summary-card .label {
  font-size: 13px;
  color: var(--text-sub);
  margin-top: 5px;
}

/* ── Calendar grid ── */
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(265px, 1fr));
  gap: 16px;
}

.month-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
}

.month-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.month-title .hol-badge {
  font-size: 11px;
  background: var(--primary-light);
  color: var(--primary);
  padding: 2px 8px;
  border-radius: 999px;
  font-weight: 600;
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 1px;
  text-align: center;
}

.cal-dow {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-sub);
  padding: 4px 0 6px;
}
.cal-dow.sun { color: var(--holiday-red); }
.cal-dow.sat { color: var(--primary); }

.cal-day {
  font-size: 13px;
  padding: 5px 2px;
  border-radius: 50%;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  cursor: default;
}
.cal-day.empty { visibility: hidden; }
.cal-day.sunday  { color: var(--holiday-red); }
.cal-day.saturday { color: var(--primary); }
.cal-day.holiday {
  background: #FFF5F5;
  color: var(--holiday-red);
  font-weight: 700;
}
.cal-day.today {
  background: var(--primary);
  color: var(--white);
  font-weight: 800;
}

.holiday-list {
  margin-top: 10px;
  border-top: 1px solid var(--border);
  padding-top: 8px;
}
.holiday-item {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  padding: 3px 0;
}
.holiday-item .h-date { color: var(--holiday-red); font-weight: 600; flex-shrink: 0; }
.holiday-item .h-name { color: var(--text-sub); text-align: right; }

/* ── Calculator forms ── */
.calc-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
}
.calc-card h2 {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 18px;
}

.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-sub);
}
.form-control {
  padding: 10px 14px;
  border: 2px solid var(--border);
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  color: var(--text-main);
  background: var(--white);
  transition: border-color 0.15s;
  min-width: 110px;
  -webkit-appearance: none;
  appearance: none;
}
.form-control:focus {
  outline: none;
  border-color: var(--primary);
}

.btn-primary {
  padding: 10px 24px;
  background: var(--primary);
  color: var(--white);
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
  height: 44px;
}
.btn-primary:hover { background: #154a8a; }

/* ── Result items ── */
.results-section { margin-top: 8px; }

.result-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 10px;
  box-shadow: var(--shadow);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.result-item .badge {
  background: var(--primary);
  color: var(--white);
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
}
.result-item .badge.green  { background: #2F855A; }
.result-item .info { flex: 1; min-width: 180px; }
.result-item .info .main-text {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 3px;
}
.result-item .info .sub-text {
  font-size: 13px;
  color: var(--text-sub);
}

/* ── Workday result ── */
.workday-result-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow);
  text-align: center;
  margin-top: 8px;
}
.big-num {
  font-size: 56px;
  font-weight: 800;
  color: var(--primary);
  line-height: 1;
  letter-spacing: -2px;
}
.big-unit { font-size: 20px; color: var(--text-sub); margin-top: 6px; }
.workday-breakdown {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-top: 20px;
  flex-wrap: wrap;
}
.breakdown-item { text-align: center; }
.breakdown-item .bnum { font-size: 22px; font-weight: 700; color: var(--text-main); }
.breakdown-item .blabel { font-size: 12px; color: var(--text-sub); margin-top: 2px; }

/* ── Golden holiday ── */
.golden-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 12px;
  box-shadow: var(--shadow);
}
.golden-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}
.rank-badge {
  display: inline-flex;
  width: 30px;
  height: 30px;
  background: var(--primary);
  color: var(--white);
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
  flex-shrink: 0;
}
.rank-badge.gold   { background: #D69E2E; }
.rank-badge.silver { background: #718096; }
.rank-badge.bronze { background: #B7791F; }

.golden-title   { font-size: 16px; font-weight: 700; }
.golden-meta    { font-size: 13px; color: var(--text-sub); margin-bottom: 10px; }

.day-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.pill {
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}
.pill.free     { background: #EBF8FF; color: #2B6CB0; }
.pill.holiday  { background: #FFF5F5; color: var(--holiday-red); }
.pill.vacation { background: #F0FFF4; color: #276749; }

/* ── Privacy ── */
.privacy-content { max-width: 800px; }
.privacy-content h2 {
  font-size: 16px; font-weight: 700;
  margin: 28px 0 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}
.privacy-content p, .privacy-content li {
  font-size: 14px; color: var(--text-sub); line-height: 1.85;
}
.privacy-content ul { padding-left: 20px; margin-top: 6px; }
.privacy-content li + li { margin-top: 3px; }

/* ── Page description ── */
.page-desc {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 20px;
  box-shadow: var(--shadow);
}
.page-desc p {
  font-size: 15px;
  color: var(--text-sub);
  line-height: 1.85;
}

/* ── Holiday guide ── */
.guide-section { margin-top: 40px; }
.guide-section h2 {
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 8px;
  letter-spacing: -0.3px;
}
.guide-intro {
  font-size: 14px;
  color: var(--text-sub);
  margin-bottom: 20px;
  line-height: 1.85;
  max-width: 760px;
}
.guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}
.guide-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
}
.guide-card h3 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 7px;
}
.guide-card p {
  font-size: 13px;
  color: var(--text-sub);
  line-height: 1.75;
}

/* ── Empty state ── */
.empty-state {
  text-align: center;
  padding: 48px 16px;
  color: var(--text-sub);
  font-size: 15px;
}
.empty-icon { font-size: 40px; margin-bottom: 12px; }

/* ── Footer ── */
.footer {
  background: var(--white);
  border-top: 1px solid var(--border);
  padding: 24px 16px;
  text-align: center;
}
.footer-inner { max-width: 1100px; margin: 0 auto; }
.footer p      { font-size: 14px; color: var(--text-sub); }
.footer a      { color: var(--primary); }
.footer-sub    { font-size: 12px; margin-top: 6px; }

/* ── Responsive ── */
@media (max-width: 600px) {
  .nav-logo { font-size: 15px; }
  .summary-card { min-width: 100px; padding: 12px 14px; }
  .summary-card .num { font-size: 24px; }
  .calendar-grid { grid-template-columns: 1fr; }
  .form-row { flex-direction: column; }
  .form-control { width: 100%; }
  .result-item { flex-direction: column; align-items: flex-start; }
  .workday-result-card { padding: 20px; }
  .big-num { font-size: 44px; }
}
