:root {
  color-scheme: light;
  --ink: #27221d;
  --muted: #685f56;
  --line: #e8d9b5;
  --paper: #fff8e6;
  --panel: #ffffff;
  --brand: #ffdf5d;
  --deep: #173533;
  --shadow: 0 16px 34px rgba(49, 36, 18, .1);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, var(--deep) 0, var(--deep) 430px, #fbf7ec 430px, #fffdf8 100%);
  color: var(--ink);
  font-family: "Segoe UI", "Malgun Gothic", "Apple SD Gothic Neo", Arial, sans-serif;
  line-height: 1.55;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

h1,
h2,
p,
dl,
dd {
  margin: 0;
}

.type-header,
main,
.type-footer {
  width: min(1120px, calc(100% - 34px));
  margin: 0 auto;
}

.type-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
  color: #fffaf0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
}

.brand img {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 250, 240, .48);
  border-radius: var(--radius);
  background: #fff8d8;
}

.type-header nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.type-header nav a,
.type-shortcuts a,
.primary-link,
.secondary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 12px;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 900;
}

.type-header nav a {
  border: 1px solid rgba(255, 250, 240, .24);
  background: rgba(255, 255, 255, .08);
}

.type-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 22px;
  align-items: end;
  padding: 38px 0 36px;
  color: #fffaf0;
}

.eyebrow {
  margin-bottom: 8px;
  color: var(--brand);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1 {
  max-width: 820px;
  font-size: clamp(36px, 5.4vw, 64px);
  line-height: 1.04;
  letter-spacing: 0;
}

.lead {
  max-width: 760px;
  margin-top: 16px;
  color: rgba(255, 250, 240, .82);
  font-size: 18px;
}

.hero-note {
  padding: 18px;
  border: 1px solid rgba(255, 250, 240, .24);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .1);
  box-shadow: 0 18px 42px rgba(0, 0, 0, .22);
}

.hero-note strong {
  display: block;
  color: #ffdf5d;
  font-size: 18px;
}

.hero-note p {
  margin-top: 8px;
  color: rgba(255, 250, 240, .8);
  font-size: 14px;
}

.type-shortcuts {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 8px;
  margin-top: 2px;
  padding: 12px;
  border: 1px solid rgba(45, 37, 29, .08);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .96);
  box-shadow: var(--shadow);
}

.type-shortcuts a {
  border: 1px solid var(--line);
  background: #fffaf0;
  color: #453a2f;
}

.type-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 24px 0 34px;
}

.type-card {
  position: relative;
  min-width: 0;
  padding: 18px;
  border: 1px solid color-mix(in srgb, var(--accent) 28%, var(--line));
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, var(--soft), #ffffff 54%),
    var(--panel);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.type-card::after {
  content: "";
  position: absolute;
  right: -46px;
  bottom: -54px;
  width: 150px;
  height: 150px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 12%, transparent);
}

.card-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.code {
  color: var(--accent);
  font-size: 34px;
  font-weight: 950;
  line-height: 1;
}

.type-avatar {
  position: relative;
  z-index: 1;
  flex: 0 0 104px;
  width: 104px;
  aspect-ratio: 1;
  border: 1px solid color-mix(in srgb, var(--accent) 22%, var(--line));
  border-radius: var(--radius);
  background: var(--soft);
  box-shadow: 0 12px 24px rgba(49, 36, 18, .12);
  overflow: hidden;
}

.type-avatar wio-zoomable-image {
  width: 100%;
  height: 100%;
  --wio-image-fit: cover;
}

.type-avatar wio-zoomable-image[hidden] {
  display: none;
}

.type-avatar .sturgle {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 74px;
  height: 66px;
  transform: translate(-50%, -50%);
}

.type-avatar .shape-c,
.type-avatar .shape-g,
.type-avatar .shape-k,
.type-avatar .shape-o {
  transform: translate(-50%, -50%) rotate(-2deg);
}

.type-avatar .shape-d,
.type-avatar .shape-h,
.type-avatar .shape-l,
.type-avatar .shape-p {
  transform: translate(-50%, -50%) rotate(2deg);
}

.type-card h2 {
  position: relative;
  z-index: 1;
  margin-top: 14px;
  font-size: 24px;
  line-height: 1.18;
}

.summary {
  position: relative;
  z-index: 1;
  margin-top: 10px;
  color: #4f463e;
}

.type-card dl {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.type-card dl div {
  padding: 10px;
  border: 1px solid rgba(45, 37, 29, .08);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .72);
}

.type-card dt {
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
}

.type-card dd {
  margin-top: 4px;
  color: var(--muted);
  font-size: 14px;
}

.sturgle {
  position: relative;
  flex: 0 0 auto;
  width: 78px;
  height: 70px;
  border: 2px solid #2d251d;
  border-radius: 42% 48% 46% 44%;
  background: var(--accent);
  box-shadow: 0 5px 0 rgba(45, 37, 29, .16);
}

.sturgle::before,
.sturgle::after {
  content: "";
  position: absolute;
  top: -10px;
  width: 22px;
  height: 24px;
  border: 2px solid #2d251d;
  border-bottom: 0;
  border-radius: 16px 16px 4px 4px;
  background: var(--mark);
}

.sturgle::before {
  left: 10px;
  transform: rotate(-18deg);
}

.sturgle::after {
  right: 10px;
  transform: rotate(18deg);
}

.sturgle span {
  position: absolute;
  left: 17px;
  top: 25px;
  width: 10px;
  height: 12px;
  border-radius: 999px;
  background: #2d251d;
  box-shadow: 31px 0 0 #2d251d;
}

.sturgle span::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 19px;
  width: 20px;
  height: 9px;
  border-bottom: 3px solid #2d251d;
  border-radius: 0 0 18px 18px;
}

.shape-b,
.shape-f,
.shape-j,
.shape-n {
  border-radius: 50% 42% 48% 42%;
}

.shape-c,
.shape-g,
.shape-k,
.shape-o {
  transform: rotate(-2deg);
}

.shape-d,
.shape-h,
.shape-l,
.shape-p {
  transform: rotate(2deg);
}

.shape-e::before,
.shape-i::before,
.shape-m::before {
  height: 30px;
  border-radius: 999px 999px 4px 4px;
}

.shape-e::after,
.shape-i::after,
.shape-m::after {
  height: 30px;
  border-radius: 999px 999px 4px 4px;
}

.type-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 26px 0 34px;
  border-top: 1px solid var(--line);
}

.type-footer strong,
.type-footer span {
  display: block;
}

.type-footer span {
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 980px) {
  body {
    background:
      linear-gradient(180deg, var(--deep) 0, var(--deep) 560px, #fbf7ec 560px, #fffdf8 100%);
  }

  .type-hero,
  .type-grid {
    grid-template-columns: 1fr;
  }

  .type-shortcuts {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  body {
    background:
      linear-gradient(180deg, var(--deep) 0, var(--deep) 690px, #fbf7ec 690px, #fffdf8 100%);
  }

  .type-header,
  .type-footer {
    align-items: stretch;
    flex-direction: column;
    display: flex;
  }

  .type-header nav {
    justify-content: stretch;
  }

  .type-header nav a {
    flex: 1 1 120px;
  }

  .type-shortcuts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .card-top {
    align-items: flex-start;
  }

  .code {
    font-size: 30px;
  }
}

/* Playful personality gallery pass */
:root {
  --ink: #2d251d;
  --muted: #6b5d50;
  --line: #ead7a4;
  --paper: #fff6df;
  --panel: #fffdfa;
  --brand: #ffd84d;
  --deep: #24514d;
  --shadow: 0 14px 28px rgba(45, 37, 29, .12);
}

html {
  overflow-x: hidden;
}

body {
  overflow-x: hidden;
  background:
    linear-gradient(90deg, rgba(255, 216, 77, .12) 1px, transparent 1px) 0 0 / 42px 42px,
    linear-gradient(180deg, #fff7df 0, #fffdf7 44%, #f4fbf8 100%);
}

.type-header {
  color: var(--ink);
}

.type-header nav a {
  border-color: rgba(45, 37, 29, .12);
  background: rgba(255, 255, 255, .82);
  color: #32281f;
  box-shadow: 0 3px 0 rgba(45, 37, 29, .08);
}

.brand img {
  border-color: rgba(45, 37, 29, .16);
  background: #fff;
}

.type-hero {
  position: relative;
  color: var(--ink);
}

.type-hero::before {
  content: "16 TYPES";
  position: absolute;
  top: 18px;
  left: 0;
  display: grid;
  place-items: center;
  width: 88px;
  height: 30px;
  border: 1px solid rgba(45, 37, 29, .18);
  border-radius: var(--radius);
  background: #25a58c;
  color: #fffaf0;
  font-size: 12px;
  font-weight: 950;
  transform: rotate(-4deg);
  box-shadow: 0 5px 0 rgba(45, 37, 29, .12);
}

.type-hero .eyebrow {
  color: #d98300;
}

.lead {
  color: #584a3d;
}

.hero-note {
  border-color: rgba(45, 37, 29, .14);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .96), rgba(224, 251, 244, .88)),
    #fff;
  box-shadow: 0 18px 38px rgba(45, 37, 29, .14);
}

.hero-note strong {
  color: #147765;
}

.hero-note p {
  color: #584a3d;
}

.type-shortcuts {
  border-color: rgba(45, 37, 29, .1);
  background: #fffdfa;
}

.type-shortcuts a {
  min-height: 44px;
  background: #fff7df;
  box-shadow: 0 4px 0 rgba(45, 37, 29, .06);
  transition: transform 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

.type-shortcuts a:hover {
  border-color: rgba(255, 108, 95, .42);
  box-shadow: 0 7px 0 rgba(255, 108, 95, .08);
  transform: translateY(-2px);
}

.type-card {
  box-shadow: 0 12px 24px rgba(45, 37, 29, .1);
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.type-card:hover {
  box-shadow: 0 18px 34px rgba(45, 37, 29, .14);
  transform: translateY(-3px);
}

.type-avatar {
  cursor: zoom-in;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.type-avatar::after {
  content: "+";
  position: absolute;
  right: 7px;
  bottom: 7px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(45, 37, 29, .16);
  border-radius: 999px;
  background: rgba(255, 255, 255, .92);
  color: var(--accent);
  font-size: 20px;
  font-weight: 950;
  line-height: 1;
  box-shadow: 0 4px 0 rgba(45, 37, 29, .08);
}

.type-avatar:hover,
.type-avatar:focus-within {
  box-shadow: 0 14px 26px rgba(45, 37, 29, .16);
  outline: 3px solid color-mix(in srgb, var(--accent) 32%, white);
  outline-offset: 3px;
  transform: translateY(-2px) rotate(-1deg);
}

@media (prefers-reduced-motion: reduce) {
  .type-shortcuts a,
  .type-card,
  .type-avatar {
    transition: none;
  }
}

@media (max-width: 980px) {
  body {
    background:
      linear-gradient(90deg, rgba(255, 216, 77, .1) 1px, transparent 1px) 0 0 / 34px 34px,
      linear-gradient(180deg, #fff7df 0, #fffdf7 56%, #f4fbf8 100%);
  }

  .type-hero {
    padding-top: 52px;
  }
}

@media (max-width: 700px) {
  .type-hero::before {
    top: 14px;
  }

  h1 {
    font-size: clamp(34px, 10vw, 46px);
  }

}
