:root {
  --panel: #0f0f0f;
  --panel-2: #171717;
  --line: #303030;
  --muted: #b8b8b8;
  --soft: #f7f7f7;
  --accent: #006CFF;
}

body {
  background: #000;
  color: #fff;
  font-family: "Pretendard Variable", Pretendard, "Malgun Gothic", Arial, sans-serif;
  margin: 0;
}

.font-detail {
  max-width: 1160px;
  margin: 92px auto 64px;
  padding: 0 18px;
}

.font-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.9rem;
}

.font-breadcrumb a {
  color: #fff;
  text-decoration: none;
}

.font-breadcrumb a:hover {
  color: var(--accent);
}

.font-title-wrap {
  position: relative;
  background: var(--panel);
  padding: 54px 28px 46px;
  border: 1px solid var(--line);
  border-radius: 18px 18px 0 0;
  text-align: center;
  overflow: hidden;
}

.font-title-wrap::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent);
}

.font-title-label {
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 14px;
  font-weight: 700;
}

.font-title {
  font-size: 3.45rem;
  font-weight: 800;
  line-height: 1.2;
  overflow-wrap: anywhere;
  color: #fff;
  margin: 0;
}

.summary-card {
  background: #111;
  border: 1px solid var(--line);
  border-top: 0;
  padding: 20px 24px;
  color: #e9e9e9;
  line-height: 1.8;
}

.summary-card p {
  margin: 0;
}

.info-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  background: var(--panel);
  color: #fff;
  border: 1px solid var(--line);
  border-top: 0;
  font-size: 1rem;
}

.info-cell {
  min-width: 0;
  padding: 18px 16px;
  border-right: 1px solid var(--line);
  border-top: 1px solid rgba(255,255,255,.04);
  color: #f3f3f3;
  font-weight: 700;
}

.info-cell:last-child {
  border-right: none;
}

.info-label {
  color: var(--muted);
  display: block;
  font-size: .75rem;
  margin-bottom: 8px;
  font-weight: 700;
}

.info-cell a {
  color: #f3f3f3 !important;
  text-decoration: none;
}

.info-cell a:hover {
  color: var(--accent) !important;
  text-decoration: none;
}

.controls-bar {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 12px;
  padding: 16px;
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-top: 0;
}

.controls-bar label {
  color: #fff;
  font-weight: 800;
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #101010;
}

.font-detail input[type="range"] {
  --range-progress: 0%;
  width: 100%;
  height: 20px;
  margin: 0;
  padding: 0;
  background: transparent;
  accent-color: var(--accent);
  -webkit-appearance: none;
  appearance: none;
}

.font-detail input[type="range"]::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 999px;
  background: linear-gradient(to right, var(--accent) 0%, var(--accent) var(--range-progress), #d9d9d9 var(--range-progress), #d9d9d9 100%);
}

.font-detail input[type="range"]::-webkit-slider-thumb {
  width: 18px;
  height: 18px;
  margin-top: -6px;
  border: 0;
  border-radius: 50%;
  background: var(--accent);
  -webkit-appearance: none;
  appearance: none;
}

.font-detail input[type="range"]::-moz-range-track {
  height: 6px;
  border-radius: 999px;
  background: #d9d9d9;
}

.font-detail input[type="range"]::-moz-range-progress {
  height: 6px;
  border-radius: 999px;
  background: var(--accent);
}

.font-detail input[type="range"]::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border: 0;
  border-radius: 50%;
  background: var(--accent);
}

.font-detail .preview-box {
  background: #fff !important;
  color: #000 !important;
  border-radius: 0 0 18px 18px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-top: 0;
  box-shadow: 0 22px 48px rgba(0,0,0,.28);
}

.font-detail .preview-area {
  background: #fff !important;
  color: #111 !important;
  -webkit-text-fill-color: #111;
  caret-color: #111;
  min-height: 310px;
  padding: 46px 34px;
  font-size: 2rem;
  text-align: center;
  outline: none;
  border: none;
  line-height: 1.5;
  word-break: break-word;
  white-space: pre-wrap;
  display: flex;
  align-items: center;
  justify-content: center;
}

.font-detail .desc-bar {
  background: #050505 !important;
  color: #b8b8b8 !important;
  padding: 22px 28px;
  font-size: 1.04rem;
  text-align: center;
  line-height: 1.7;
  border-top: 1px solid #222;
}

.font-detail .desc-bar span,
.font-detail .desc-bar p {
  color: #b8b8b8 !important;
  -webkit-text-fill-color: #b8b8b8;
}

.font-detail .desc-label {
  font-size: .8rem;
  color: #858585 !important;
  display: block;
  margin-bottom: 8px;
  font-weight: 700;
}

.font-detail .desc-bar .desc-label {
  color: #858585 !important;
  -webkit-text-fill-color: #858585;
}

.seo-content {
  background: #0b0b0b;
  border: 1px solid var(--line);
  border-radius: 14px;
  margin-top: 24px;
  padding: 24px 28px;
  line-height: 1.8;
  color: #e6e6e6;
}

.seo-content h2 {
  color: #fff;
  font-size: 1.32rem;
  margin: 0 0 12px;
}

.seo-content p {
  margin: 0 0 14px;
}

.seo-content p:last-child {
  margin-bottom: 0;
}

.license-section {
  background: #050505;
  border: 1px solid var(--line);
  border-radius: 14px;
  margin-top: 18px;
  padding: 26px 28px;
  color: #d5d5d5;
}

.license-section h2,
.license-section h3 {
  color: #fff;
  margin: 0;
}

.license-section h2 {
  font-size: 1.28rem;
  margin-bottom: 10px;
}

.license-section h3 {
  font-size: 1rem;
  margin-bottom: 12px;
}

.license-note,
.license-disclaimer {
  color: #9f9f9f;
  line-height: 1.75;
}

.license-note {
  margin: 0 0 18px;
}

.license-copy {
  border-top: 1px solid #242424;
  padding-top: 18px;
}

.license-copy ul {
  margin: 0;
  padding-left: 18px;
}

.license-copy li {
  color: #c6c6c6;
  line-height: 1.8;
  margin-bottom: 7px;
}

.license-table-wrap {
  margin-top: 22px;
  overflow-x: auto;
  border: 1px solid #242424;
  border-radius: 10px;
}

.license-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 680px;
}

.license-table th,
.license-table td {
  border-bottom: 1px solid #242424;
  padding: 14px 16px;
  text-align: left;
  vertical-align: top;
}

.license-table th {
  background: #111;
  color: #f2f2f2;
  font-size: .92rem;
}

.license-table td {
  color: #bdbdbd;
  line-height: 1.65;
}

.license-table tr:last-child th,
.license-table tr:last-child td {
  border-bottom: 0;
}

.license-status-ok {
  color: #d8e8ff !important;
  font-weight: 700;
}

.license-status-limited {
  color: #ffd6ad !important;
  font-weight: 700;
}

.license-status-no {
  color: #ffb1b1 !important;
  font-weight: 700;
}

.license-source-link {
  display: inline-flex;
  margin-top: 14px;
  color: var(--accent) !important;
  font-weight: 700;
  text-decoration: none;
}

.license-source-link:hover {
  color: #fff !important;
  text-decoration: underline;
}

.faq-section,
.same-foundry-section,
.related-section {
  background: #0b0b0b;
  border: 1px solid var(--line);
  border-radius: 14px;
  margin-top: 18px;
  padding: 24px 28px;
  color: #d8d8d8;
}

.faq-section h2,
.same-foundry-section h2,
.related-section h2 {
  color: #fff;
  font-size: 1.24rem;
  margin: 0 0 16px;
}

.same-foundry-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.same-foundry-head h2 {
  margin: 0;
}

.same-foundry-more {
  color: #e8e8e8 !important;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.same-foundry-more:hover {
  color: var(--accent) !important;
  text-decoration: none;
}

.same-foundry-scroller {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(220px, 320px);
  gap: 12px;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 2px 0 10px;
  scrollbar-color: #5b5b5b #050505;
  scrollbar-width: thin;
}

.same-foundry-scroller::-webkit-scrollbar {
  height: 8px;
}

.same-foundry-scroller::-webkit-scrollbar-track {
  background: #050505;
  border-radius: 999px;
}

.same-foundry-scroller::-webkit-scrollbar-thumb {
  background: #5b5b5b;
  border-radius: 999px;
}

.same-foundry-card {
  display: block;
  min-width: 0;
  padding: 18px 20px;
  border: 1px solid #303030;
  border-radius: 10px;
  background: #111;
  color: #e8e8e8 !important;
  text-decoration: none;
}

.same-foundry-card:hover {
  border-color: var(--accent);
  color: #fff !important;
  text-decoration: none;
}

.same-foundry-card strong,
.same-foundry-card span {
  display: block;
}

.same-foundry-card strong {
  min-height: 1.6em;
  color: #fff;
  font-size: 1.32rem;
  line-height: 1.35;
  margin-bottom: 10px;
  overflow-wrap: anywhere;
}

.same-foundry-card span {
  color: #a8a8a8 !important;
  font-size: .9rem;
  line-height: 1.5;
}

.faq-item {
  border-top: 1px solid #242424;
  padding: 16px 0 0;
  margin-top: 16px;
}

.faq-item:first-of-type {
  border-top: 0;
  padding-top: 0;
  margin-top: 0;
}

.faq-item h3 {
  color: #f5f5f5;
  font-size: 1rem;
  margin: 0 0 8px;
}

.faq-item p {
  margin: 0;
  color: #b8b8b8;
  line-height: 1.75;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.related-card {
  display: block;
  min-width: 0;
  padding: 16px;
  border: 1px solid #2c2c2c;
  border-radius: 10px;
  background: #111;
  color: #e8e8e8 !important;
  text-decoration: none;
}

.related-card:hover {
  border-color: var(--accent);
  color: #fff !important;
  text-decoration: none;
}

.related-card strong,
.related-card span {
  display: block;
}

.related-card strong {
  font-size: 1.02rem;
  margin-bottom: 8px;
  color: #fff;
  overflow-wrap: anywhere;
}

.related-card span {
  color: #a8a8a8 !important;
  font-size: 0.9rem;
}

.btn-group {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: center;
  margin-top: 30px;
  flex-wrap: wrap;
  width: 100%;
}

.font-detail .btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 32px;
  border: 1px solid #fff;
  border-radius: 10px;
  background: #000;
  color: #fff !important;
  font-weight: bold;
  font-size: 1.1rem;
  text-decoration: none;
  overflow: hidden;
  box-shadow: 0 2px 10px #fff1;
  transition: background .3s, border-color .3s, color .2s, box-shadow .3s;
  width: 100%;
  max-width: 340px;
  box-sizing: border-box;
}

.font-detail .btn:hover,
.font-detail .btn:focus,
.font-detail .btn:active {
  background: #fff;
  color: #000 !important;
  border-color: #fff;
  box-shadow: 0 4px 24px #fff2;
  text-decoration: none;
}

.font-detail .btn-group .btn:last-child {
  background: #006CFF;
  border-color: #006CFF;
  color: #fff !important;
  box-shadow: 0 6px 20px rgba(0, 108, 255, .28);
}

.font-detail .btn-group .btn:last-child:hover,
.font-detail .btn-group .btn:last-child:focus,
.font-detail .btn-group .btn:last-child:active {
  background: #006CFF;
  border-color: #006CFF;
  color: #fff !important;
  box-shadow: 0 8px 28px rgba(0, 108, 255, .38);
}

@media (max-width: 900px) {
  .info-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .controls-bar {
    grid-template-columns: 1fr;
  }

  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .same-foundry-scroller {
    grid-auto-columns: minmax(210px, 42vw);
  }
}

@media (max-width: 700px) {
  .font-detail {
    margin: 84px auto 42px;
    padding: 0 12px;
  }

  .info-row {
    grid-template-columns: 1fr;
  }

  .info-cell {
    border-right: none;
    border-bottom: 1px solid var(--line);
  }

  .font-title {
    font-size: 2.2rem;
  }

  .font-title-wrap {
    padding: 38px 18px 32px;
  }

  .preview-area {
    min-height: 220px;
    padding: 24px 18px;
  }

  .controls-bar label {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 12px;
  }

  .font-detail .btn {
    width: 100%;
    max-width: none;
  }

  .btn-group {
    flex-direction: column;
    gap: 10px;
  }

  .related-grid {
    grid-template-columns: 1fr;
  }

  .same-foundry-section,
  .related-section,
  .faq-section {
    padding: 20px 16px;
  }

  .same-foundry-head {
    align-items: flex-start;
  }

  .same-foundry-scroller {
    grid-auto-columns: minmax(210px, 78vw);
  }
}
