/* U-Work portal — same tokens as the U-Work KPI 0.6.0 app (App.axaml): ink, neutral surfaces, orange action.
   The web action colour is the app's action hue darkened to keep white button text at WCAG AA (≥ 4.5:1). */
@font-face {
  font-family: "Pretendard";
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  src: local("Pretendard Regular"), local("Pretendard-Regular"), url("/fonts/Pretendard-Regular.otf") format("opentype");
}
@font-face {
  font-family: "Pretendard";
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  src: local("Pretendard SemiBold"), local("Pretendard-SemiBold"), url("/fonts/Pretendard-SemiBold.otf") format("opentype");
}

:root {
  --ink: #1f2935;
  --ink-2: #2c3846;
  --text: #1f2935;
  --muted: #5d6168;
  --line: #e3e4e6;
  --line-strong: #cfd3d8;
  --surface: #ffffff;
  --canvas: #f5f6f8;
  --table-head-text: #4a5361;
  --action: #c2510c;
  --action-hover: #a8460a;
  --selection: #ffe9da;
  --selection-text: #8a3a0a;
  --on-ink: #ffffff;
  --on-ink-muted: #c9d0d8;
  --error: #b42318;
  --focus: #1f6feb;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgb(31 41 53 / 6%), 0 8px 24px rgb(31 41 53 / 6%);
  --font: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--surface);
  word-break: keep-all;
  overflow-wrap: anywhere;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3 { margin: 0; font-weight: 600; line-height: 1.3; letter-spacing: -0.01em; }
p { margin: 0; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
[hidden] { display: none !important; }

.wrap { width: min(1200px, 100% - 48px); margin-inline: auto; }

.skip {
  position: absolute; left: 16px; top: -48px; z-index: 20;
  padding: 8px 14px; border-radius: var(--radius-sm);
  background: var(--ink); color: var(--on-ink); text-decoration: none;
}
.skip:focus { top: 12px; }

/* Top bar */
.topbar {
  position: sticky; top: 0; z-index: 10;
  background: rgb(255 255 255 / 96%);
  border-bottom: 1px solid var(--line);
}
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-size: 20px; font-weight: 600; color: var(--ink); }
.brand img { width: 32px; height: 32px; }
.nav { display: flex; gap: 4px; }
.nav a {
  padding: 8px 12px; border-radius: var(--radius-sm);
  color: var(--table-head-text); text-decoration: none; font-size: 15px; font-weight: 600;
}
.nav a:hover { background: var(--canvas); color: var(--ink); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 22px;
  border: 1px solid transparent; border-radius: var(--radius-sm);
  font: inherit; font-size: 16px; font-weight: 600; line-height: 1.2;
  text-decoration: none; cursor: pointer;
  transition: background-color .15s, border-color .15s, color .15s;
}
.btn-primary { background: var(--action); color: #fff; }
.btn-primary:hover { background: var(--action-hover); }
.btn-primary:disabled { background: var(--line-strong); color: var(--table-head-text); cursor: progress; }
.btn-secondary { background: var(--surface); color: var(--ink); border-color: var(--line-strong); }
.btn-secondary:hover { background: var(--canvas); border-color: var(--table-head-text); }
.btn-ghost { background: transparent; color: var(--on-ink); border-color: rgb(255 255 255 / 45%); }
.btn-ghost:hover { background: rgb(255 255 255 / 10%); border-color: #fff; }
.btn-disabled, .btn-disabled:disabled {
  background: var(--canvas); color: var(--table-head-text); border-color: var(--line); cursor: not-allowed;
}
.btn-block { width: 100%; }

/* Hero */
.hero { background: var(--ink); color: var(--on-ink); }
.hero-inner {
  display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: 56px; align-items: center; padding-block: 88px 96px;
}
.eyebrow { font-size: 14px; font-weight: 600; letter-spacing: .04em; color: var(--action-hover); margin-bottom: 12px; }
.hero .eyebrow { color: #ffb689; }
.hero h1 { font-size: clamp(32px, 4.2vw, 52px); line-height: 1.22; letter-spacing: -0.02em; }
.lead { margin-top: 20px; max-width: 40em; font-size: 18px; color: var(--on-ink-muted); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }

.release-panel {
  background: var(--surface); color: var(--text);
  border-radius: 16px; padding: 28px; box-shadow: 0 24px 48px rgb(0 0 0 / 24%);
}
.release-head { display: flex; align-items: center; gap: 16px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.release-head img { width: 56px; height: 56px; }
.release-title { font-size: 20px; font-weight: 600; }
.release-sub { color: var(--muted); font-size: 14px; }
.release-list { margin: 0; }
.release-list div, .channels div {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
}
.release-list div { padding-block: 14px; border-bottom: 1px solid var(--line); }
.release-list div:last-child { border-bottom: 0; padding-bottom: 0; }
.release-list dt, .channels dt { color: var(--table-head-text); font-size: 14px; font-weight: 600; flex: none; }
.release-list dd, .channels dd { margin: 0; text-align: right; font-weight: 600; min-width: 0; }

/* Sections */
.section { padding-block: 96px; }
.section-alt { background: var(--canvas); border-block: 1px solid var(--line); }
.section-title { font-size: clamp(26px, 3vw, 36px); letter-spacing: -0.02em; }
.section-lead { margin-top: 12px; max-width: 46em; color: var(--muted); font-size: 17px; }

.features {
  list-style: none; margin: 40px 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px;
}
.feature {
  padding: 28px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface);
}
.feature h3 { font-size: 19px; margin-top: 18px; }
.feature p { margin-top: 8px; color: var(--muted); }
.icon {
  display: inline-grid; place-items: center; width: 44px; height: 44px;
  border-radius: 10px; background: var(--selection); color: var(--selection-text);
}
.icon svg, .product-badge svg {
  width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
}

/* Download */
.products {
  margin-top: 40px;
  display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr); gap: 20px;
}
.product {
  display: flex; flex-direction: column; gap: 16px;
  padding: 28px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--surface); box-shadow: var(--shadow);
}
.product-main { border-color: var(--line-strong); }
.product-head { display: flex; align-items: center; gap: 14px; }
.product-head img { width: 40px; height: 40px; flex: none; }
.product-head h3 { font-size: 22px; }
.platform { color: var(--muted); font-size: 14px; }
.product-badge {
  display: inline-grid; place-items: center; flex: none; width: 40px; height: 40px;
  border-radius: 10px; background: var(--ink); color: var(--on-ink); font-weight: 600; font-size: 18px;
}
.product-pending .product-badge { background: var(--canvas); color: var(--table-head-text); border: 1px solid var(--line); }
.product-desc { color: var(--text); }
.channels { margin: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.channels div { padding: 12px 16px; }
.channels div + div { border-top: 1px solid var(--line); }
.hint { color: var(--muted); font-size: 14px; margin-top: auto; }
.product .btn-block { margin-top: 4px; }
/* Android · iPhone: same width, side by side when the card is wide enough, stacked on narrow cards and phones. */
.store-buttons { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; margin-top: 4px; }
.store-buttons .btn { width: 100%; text-align: center; }
.store-buttons .btn[hidden] { display: none; }

/* Updates */
.updates { margin-top: 40px; display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; }
.update { padding: 28px; border: 1px solid var(--line); border-radius: var(--radius); }
.update h3 { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; font-size: 20px; }
.pill {
  display: inline-block; padding: 2px 10px; border-radius: 999px;
  background: var(--selection); color: var(--selection-text); font-size: 13px; font-weight: 600;
}
.notes { margin: 16px 0 0; padding-left: 20px; color: var(--ink-2); }
.notes li + li { margin-top: 10px; }
.notes li::marker { color: var(--action); }
.notes:empty::before { content: "표시할 업데이트가 없습니다."; color: var(--muted); margin-left: -20px; }

/* Footer */
.footer { background: var(--canvas); border-top: 1px solid var(--line); padding-block: 40px; color: var(--muted); font-size: 14px; }
.footer-inner { display: grid; gap: 10px; }
.brand-footer { font-size: 16px; }
.brand-footer img { width: 24px; height: 24px; }
.fine a { color: var(--table-head-text); }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.footer-links a { color: var(--table-head-text); font-weight: 600; }
.footer-operator a { color: var(--table-head-text); }
/* Top menu: the two legal links stay on every width; phones drop the in-page sections and shorten the label. */
.nav-short { display: none; }
.nav a[aria-current="page"] { color: var(--ink); background: var(--canvas); }
@media (max-width: 640px) {
  .nav .nav-section, .nav .nav-full { display: none; }
  .nav .nav-short { display: inline; }
}

/* Dialog */
dialog {
  width: min(440px, 100% - 32px); padding: 0; border: 0; border-radius: 16px;
  color: var(--text); box-shadow: 0 24px 80px rgb(15 23 32 / 35%);
}
dialog::backdrop { background: rgb(15 23 32 / 60%); }
dialog form { display: grid; gap: 14px; padding: 28px; }
dialog h2 { font-size: 22px; }
dialog p { color: var(--muted); }
label { display: grid; gap: 8px; color: var(--table-head-text); font-weight: 600; font-size: 15px; }
input {
  width: 100%; min-height: 48px; padding: 12px 14px;
  border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  font: inherit; font-size: 16px; color: var(--text); background: var(--surface);
}
input:focus-visible { border-color: var(--focus); }
.error { color: var(--error); min-height: 1.6em; font-size: 14px; }
.actions { display: flex; gap: 10px; }
.actions .btn { flex: 1; }

/* Responsive: 1440 / 1024 / 768 / 390 / 360 */
@media (max-width: 1180px) {
  .products { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-main { grid-column: 1 / -1; }
}
@media (max-width: 1024px) {
  .hero-inner { gap: 40px; padding-block: 72px 80px; }
  .features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .section { padding-block: 80px; }
}
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: minmax(0, 1fr); }
  .release-panel { max-width: 560px; }
  .updates { grid-template-columns: minmax(0, 1fr); }
  .wide-only { display: none; }
}
@media (max-width: 640px) {
  .wrap { width: calc(100% - 32px); }
  .topbar-inner { height: 56px; }
  .brand { font-size: 18px; }
  .brand img { width: 28px; height: 28px; }
  .nav a { padding: 8px; font-size: 14px; }
  .hero-inner { padding-block: 48px 56px; }
  .lead { font-size: 16px; }
  .hero-actions .btn { flex: 1 1 100%; }
  .release-panel { padding: 22px; }
  .section { padding-block: 64px; }
  .features, .products { grid-template-columns: minmax(0, 1fr); margin-top: 28px; }
  .feature, .product, .update { padding: 22px; }
  .updates { margin-top: 28px; }
}
@media (max-width: 380px) {
  .nav { gap: 0; }
  .nav a { padding: 8px 6px; }
  .brand span { font-size: 17px; }
}
