:root {
  color-scheme: light;
  --ink: #17263d;
  --muted: #46566e;
  --brand: #1546c8;
  --brand-hover: #103ba9;
  --line: #dfe6f0;
  --light-blue: #edf3ff;
  --side: 28px;
  --page-width: 1160px;
  font-family: "Noto Sans KR", "Apple SD Gothic Neo", system-ui, sans-serif;
  color: var(--ink);
  background: #fff;
  font-synthesis: none;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; }
img { display: block; max-width: 100%; }
a { color: inherit; }
button, select { font: inherit; }
[hidden] { display: none !important; }

:focus-visible {
  outline: 3px solid #285df4;
  outline-offset: 4px;
}

.wrap {
  width: min(var(--page-width), calc(100% - 2 * var(--side)));
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  z-index: 2;
  inset: 12px auto auto 12px;
  padding: 10px 14px;
  background: #fff;
  border-radius: 8px;
  transform: translateY(calc(-100% - 16px));
}
.skip-link:focus { transform: none; }

.site-header {
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.masthead {
  min-height: 72px;
  display: flex;
  align-items: center;
  gap: 26px;
}

.wordmark {
  display: inline-flex;
  align-items: baseline;
  gap: .18em;
  margin-inline-end: auto;
  color: #142751;
  font-family: Poppins, system-ui, sans-serif;
  font-size: 1.43rem;
  font-weight: 700;
  letter-spacing: -.048em;
  line-height: 1.15;
  white-space: nowrap;
  text-decoration: none;
}
.wordmark span { color: var(--brand); }

.header-links {
  display: flex;
  align-items: center;
  gap: 23px;
}

.header-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--muted);
  font-size: .88rem;
  font-weight: 700;
  line-height: 1.3;
  white-space: nowrap;
  text-decoration: none;
}
.header-links a:hover { color: var(--brand); }

.language select {
  min-height: 42px;
  max-width: 100%;
  padding: 0 8px;
  border: 1px solid #d9e2f0;
  border-radius: 8px;
  background: #f7f9fe;
  color: #314665;
  font-size: .8rem;
  font-weight: 700;
  cursor: pointer;
}

.intro {
  padding-block: clamp(42px, 5.1vw, 76px);
  background: linear-gradient(#f8faff, #edf3ff);
  border-bottom: 1px solid #e2eafa;
}

.intro-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, .99fr);
  align-items: center;
  gap: clamp(28px, 4.4vw, 64px);
}

.studio-label {
  margin: 0 0 14px;
  color: var(--brand);
  font-size: .86rem;
  font-weight: 800;
  line-height: 1.45;
}

.intro h1 {
  margin: 0;
  color: #142349;
  font-size: clamp(2.45rem, 4.08vw, 3.7rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -.061em;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
.intro h1 span { display: block; }

.intro-description {
  max-width: 31rem;
  margin: 19px 0 26px;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.72;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.primary-link,
.spotlight-link {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 13px;
  border-radius: 10px;
  padding: 0 15px;
  font-size: .9rem;
  line-height: 1.3;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.primary-link {
  background: var(--brand);
  color: #fff;
}
.primary-link:hover { background: var(--brand-hover); }

.spotlight {
  isolation: isolate;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  min-height: 314px;
  padding: 27px clamp(24px, 3vw, 38px);
  border-radius: 24px;
  background:
    radial-gradient(ellipse at 90% 0%, #4779e8 0%, transparent 64%),
    linear-gradient(128deg, #0c275a 15%, #1648b7);
  color: #fff;
  box-shadow: 0 12px 35px #254c9825;
}

.spotlight-copy {
  position: relative;
  z-index: 1;
  width: 54%;
  min-width: 0;
}

.spotlight-label {
  display: table;
  margin: 0 0 15px;
  padding: 4px 10px 5px;
  border: 1px solid #ffffff66;
  border-radius: 40px;
  background: #ffffff1d;
  color: #fff;
  font-size: .73rem;
  font-weight: 800;
  line-height: 1.3;
}

.spotlight-icon,
.app-icon {
  object-fit: cover;
  flex: none;
}
.spotlight-icon {
  margin: 0 0 11px;
  border-radius: 12px;
  box-shadow: 0 4px 14px #05132e66;
}

.spotlight h2 {
  margin: 0;
  font-size: clamp(1.65rem, 2.85vw, 2.3rem);
  font-weight: 800;
  letter-spacing: -.053em;
  line-height: 1.15;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
.spotlight-description {
  margin: 10px 0 15px;
  color: #ebf2ff;
  font-size: .88rem;
  line-height: 1.5;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
.spotlight-link {
  min-height: 42px;
  gap: 10px;
  padding-inline: 12px;
  background: #fff;
  color: #123671;
  font-size: .81rem;
}
.spotlight-link:hover { background: #e9f1ff; }
.spotlight-link:focus-visible { outline-color: #fff; }

.spotlight-screen {
  position: absolute;
  z-index: 0;
  inset-inline-end: clamp(21px, 3vw, 41px);
  bottom: -96px;
  width: clamp(139px, 37%, 184px);
  height: auto;
  transform: rotate(8deg);
  filter: drop-shadow(0 18px 21px #041c4999);
}

.catalog {
  padding-block: 51px 65px;
  scroll-margin-top: 12px;
}
.catalog h2 {
  margin: 0 0 16px;
  font-size: clamp(1.65rem, 3.1vw, 2.25rem);
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: -.057em;
}

.catalog-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 8px 14px;
  margin-bottom: 17px;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}
.filters button {
  min-height: 42px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--muted);
  font-size: .86rem;
  font-weight: 700;
  cursor: pointer;
}
.filters button:hover { border-color: #9ab4ef; }
.filters button[aria-pressed="true"] {
  border-color: #d1defe;
  background: var(--light-blue);
  color: #143a99;
  font-weight: 800;
}

.catalog-count {
  color: var(--muted);
  font-size: .84rem;
  font-weight: 700;
  white-space: nowrap;
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.app-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-width: 0;
  padding: 19px 18px 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
.app-card:hover,
.app-card:focus-within {
  border-color: #acc0ea;
  box-shadow: 0 5px 16px #1f3f8610;
}
.app-card-release {
  border-color: #d4e0fc;
  background: #f4f7ff;
}

.app-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
  gap: 8px;
  margin-bottom: 12px;
}

.app-icon {
  width: 52px;
  height: 52px;
  border-radius: 13px;
}
.app-category {
  color: var(--muted);
  font-size: .75rem;
  font-weight: 700;
  line-height: 1.4;
}
.release-label {
  display: inline-block;
  padding: 5px 9px 6px;
  border-radius: 7px;
  background: #e0eaff;
  color: #143a99;
  font-size: .77rem;
  line-height: 1.3;
  font-weight: 800;
}

.app-card h3 {
  margin: 0 0 6px;
  font-size: 1.13rem;
  line-height: 1.38;
  font-weight: 800;
  letter-spacing: -.045em;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
.app-card > p {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: .88rem;
  line-height: 1.55;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.store-link,
.store-pending {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  gap: 7px;
  min-height: 44px;
  margin-top: auto;
  font-size: .83rem;
  line-height: 1.4;
  font-weight: 800;
}
.store-link { color: var(--brand); text-decoration: none; }
.store-link:hover { color: var(--brand-hover); text-decoration: underline; }
.store-pending { color: var(--muted); font-weight: 700; }

.site-footer {
  background: #f7f9fd;
  border-top: 1px solid var(--line);
  color: var(--muted);
}
.footer-layout {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 6px 18px;
  padding-block: 20px;
  font-size: .88rem;
}
.footer-layout small { font-size: inherit; }
.footer-layout a {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
  min-height: 44px;
  color: var(--brand);
  text-decoration: none;
  font-weight: 700;
}
.footer-layout a:hover { text-decoration: underline; }

@media (max-width: 1020px) {
  .app-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
  .intro-layout { grid-template-columns: minmax(0, 1fr); }
  .intro-copy { max-width: 640px; }
  .intro h1 { font-size: clamp(2.45rem, 6vw, 3.45rem); }
  .spotlight { width: 100%; min-height: 265px; }
  .spotlight-screen { width: clamp(139px, 35%, 184px); bottom: -99px; }
}

@media (max-width: 680px) {
  :root { --side: 20px; }
  .masthead { min-height: 65px; gap: 16px; }
  .header-links { gap: 14px; }
  .app-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .catalog { padding-block: 39px 49px; }
}

@media (max-width: 480px) {
  :root { --side: 18px; }
  .masthead { min-height: 61px; gap: 10px; }
  .wordmark { font-size: 1.25rem; }
  .header-catalog { display: none !important; }
  .header-links a { font-size: .79rem; }
  .language select { min-height: 39px; font-size: .78rem; }
  .intro { padding-block: 34px 29px; }
  .intro h1 { font-size: clamp(1.87rem, 9vw, 2.52rem); }
  .intro-description { margin-block: 14px 20px; font-size: .94rem; }
  .intro-layout { gap: 24px; }
  .spotlight { min-height: 233px; border-radius: 18px; padding: 20px; }
  .spotlight-copy { width: 57%; }
  .spotlight-label { margin-bottom: 10px; }
  .spotlight-icon { width: 40px; height: 40px; margin-bottom: 8px; border-radius: 10px; }
  .spotlight-description { margin: 7px 0 11px; font-size: .77rem; }
  .spotlight-screen { width: clamp(107px, 38%, 169px); inset-inline-end: 15px; bottom: -61px; }
  .app-grid { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .app-card {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr);
    column-gap: 13px;
    padding: 13px 14px 6px;
  }
  .app-top { display: contents; }
  .app-icon { grid-column: 1; grid-row: 1 / span 2; width: 44px; height: 44px; border-radius: 11px; }
  .app-category { grid-column: 2; grid-row: 1; margin-bottom: 3px; }
  .app-card h3 { grid-column: 2; grid-row: 2; margin-bottom: 4px; }
  .app-card > p { grid-column: 2; grid-row: 3; margin-bottom: 0; }
  .store-link, .store-pending { grid-column: 2; grid-row: 4; justify-self: start; }
  .app-card-release { grid-template-columns: minmax(0, 1fr); }
  .app-card-release .release-label { grid-column: 1; grid-row: 1; justify-self: start; margin-bottom: 7px; }
  .app-card-release .app-category { grid-column: 1; grid-row: 1; justify-self: end; align-self: start; }
  .app-card-release :is(h3, p, .store-pending) { grid-column: 1; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .app-card { transition: none; }
}
