:root {
  --ink: #102535;
  --muted: #536878;
  --line: #dce6e5;
  --surface: #ffffff;
  --surface-soft: #f5faf8;
  --green: #087d64;
  --green-dark: #07654f;
  --mint: #daf4eb;
  --mint-deep: #b9ead9;
  --blue: #edf6fb;
  --orange: #fff3e7;
  --rose: #fff1ef;
  --shadow: 0 16px 40px rgba(16, 37, 53, 0.07);
  --radius: 28px;
}

* { box-sizing: border-box; }

html { scroll-behavior: auto; }

body {
  margin: 0;
  background: #fcfdfd;
  color: var(--ink);
  font-family: "Pretendard Variable", Pretendard, "Noto Sans KR", "Apple SD Gothic Neo", Arial, sans-serif;
  letter-spacing: -0.025em;
}

a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }

.container {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.header-row,
.nav {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
}

.brand-logo {
  display: block;
  width: clamp(150px, 16vw, 210px);
  height: auto;
}

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--green), var(--mint-deep));
  color: white;
  font-weight: 900;
  box-shadow: 0 10px 20px rgba(8, 125, 100, 0.18);
}

.brand-copy {
  display: grid;
  gap: 2px;
}

.brand-title {
  color: var(--ink);
  font-size: 1.12rem;
  font-weight: 900;
  line-height: 1.1;
}

.brand-title em {
  color: var(--green);
  font-style: normal;
}

.brand-copy small {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
}

.nav-links a {
  padding: 9px 12px;
  border-radius: 14px;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 800;
  white-space: nowrap;
}

.nav-links a:hover,
.nav-links a.active,
.nav-links a[aria-current="page"] {
  background: var(--mint);
  color: var(--green-dark);
}

.hero {
  padding: 70px 0 58px;
  background:
    radial-gradient(circle at 85% 20%, rgba(218, 244, 235, 0.9), transparent 30%),
    linear-gradient(180deg, #ffffff 0%, var(--surface-soft) 100%);
  border-bottom: 1px solid var(--line);
}

.page-hero {
  padding: 42px 0 30px;
  background: linear-gradient(180deg, #ffffff 0%, var(--surface-soft) 100%);
  border-bottom: 1px solid var(--line);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(320px, 0.86fr);
  gap: 44px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 8px 13px;
  border-radius: 999px;
  background: var(--mint);
  color: var(--green-dark);
  font-size: 0.86rem;
  font-weight: 900;
}

h1 {
  margin: 18px 0 16px;
  max-width: 760px;
  font-size: clamp(2.55rem, 4.7vw, 3.45rem);
  letter-spacing: -0.085em;
  line-height: 1.2;
}

.page-hero h1 {
  margin-bottom: 12px;
  font-size: clamp(2.22rem, 3.4vw, 3rem);
  letter-spacing: -0.075em;
}

.lead,
.page-hero p {
  max-width: 700px;
  margin: 0;
  color: var(--muted);
  font-size: 1.06rem;
  line-height: 1.75;
  letter-spacing: -0.035em;
}

.button-row,
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.btn,
.button {
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 24px;
  border: 1px solid var(--green);
  border-radius: 14px;
  background: var(--green);
  color: #fff;
  font-weight: 900;
  cursor: pointer;
}

.btn:hover,
.button:hover {
  background: var(--green-dark);
  border-color: var(--green-dark);
}

.btn-secondary,
.btn.secondary {
  background: var(--surface);
  border-color: var(--line);
  color: var(--green-dark);
}

.btn-secondary:hover,
.btn.secondary:hover {
  background: var(--surface-soft);
  border-color: var(--mint-deep);
  color: var(--green-dark);
}

.btn.warn { background: #bf4b2f; border-color: #bf4b2f; }
.btn:disabled { opacity: 0.48; cursor: not-allowed; }

.trust-pills,
.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 22px;
}

.trust-pill,
.pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--green-dark);
  font-size: 0.84rem;
  font-weight: 800;
}

.trust-pill.soft,
.pill.soft {
  background: var(--surface-soft);
  color: var(--muted);
}

.hero-preview {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.preview-top {
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 900;
}

.preview-result {
  padding: 24px;
}

.preview-result > span {
  display: block;
  color: var(--muted);
  font-weight: 800;
}

.preview-result > strong {
  display: block;
  margin-top: 8px;
  color: var(--green-dark);
  font-size: clamp(2rem, 4vw, 2.8rem);
  letter-spacing: -0.055em;
}

.preview-bars {
  display: grid;
  gap: 9px;
  margin: 22px 0;
}

.bar {
  height: 14px;
  border-radius: 999px;
  background: var(--mint);
}

.bar.blue {
  width: 68%;
  background: #dcecf7;
}

.mini-stack {
  display: grid;
  gap: 10px;
}

.mini-metric {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 14px;
  border-radius: 20px;
  background: var(--blue);
}

.mini-metric.mint { background: var(--surface-soft); }
.mini-metric span { color: var(--muted); font-size: 0.82rem; font-weight: 800; }
.mini-metric b { color: var(--ink); font-size: 1.12rem; }

.section {
  padding: 64px 0;
}

.tool-section {
  padding: 36px 0 58px;
  background:
    radial-gradient(circle at 12% 25%, rgba(218, 244, 235, 0.55), transparent 28%),
    #fcfdfd;
}

.section.alt,
.info-band {
  background: var(--surface-soft);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section-head,
.section-title {
  margin-bottom: 24px;
}

.section-head h2,
.section-title h2 {
  margin: 0 0 12px;
  max-width: 620px;
  font-size: clamp(1.72rem, 2.25vw, 2.18rem);
  letter-spacing: -0.06em;
  line-height: 1.28;
}

.section-head p,
.section-title p {
  max-width: 680px;
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  color: var(--green-dark);
  font-size: 0.92rem;
  font-weight: 900;
}

.section-kicker::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--green);
}

.tool-grid,
.feature-grid,
.info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

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

.tool-grid.five-tools {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.tool-grid.five-tools .tool-card:nth-child(4),
.tool-grid.five-tools .tool-card:nth-child(5) {
  min-height: 245px;
}

.tool-card,
.feature,
.article-card,
.panel,
.content-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.tool-card {
  min-height: 265px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 13px;
}

.tool-card:hover {
  transform: translateY(-2px);
  border-color: var(--mint-deep);
}

.tool-icon,
.feature-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: var(--mint);
  color: var(--green-dark);
  font-size: 1rem;
  font-weight: 900;
}

.tool-card:nth-child(2) .tool-icon { background: var(--blue); }
.tool-card:nth-child(3) .tool-icon { background: var(--orange); }

.tool-icon.image-icon {
  width: 70px;
  height: 70px;
  padding: 4px;
  border-radius: 20px;
  background: var(--mint);
  overflow: hidden;
}

.tool-icon.image-icon img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}

.guide-toc {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.guide-toc a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--green-dark);
  font-size: 0.88rem;
  font-weight: 900;
}

.guide-toc a:hover {
  background: var(--mint);
  border-color: var(--mint-deep);
}

.tag {
  width: fit-content;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
}

.tool-card h3 {
  margin: 0;
  font-size: 1.34rem;
  letter-spacing: -0.055em;
}

.tool-card p,
.feature p,
.article-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.68;
}

.faq-grid {
  display: grid;
  gap: 12px;
}

.faq-item {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: 0 10px 28px rgba(16, 37, 53, 0.04);
  overflow: hidden;
}

.faq-item summary {
  cursor: pointer;
  padding: 18px 20px;
  color: var(--ink);
  font-weight: 900;
  line-height: 1.45;
}

.faq-item p {
  margin: 0;
  padding: 0 20px 18px;
  color: var(--muted);
  line-height: 1.7;
}

.arrow {
  margin-top: auto;
  color: var(--green);
  font-weight: 900;
}

.tool-layout {
  display: grid;
  grid-template-columns: minmax(330px, 0.92fr) minmax(0, 1.08fr);
  gap: 18px;
  align-items: start;
}

.panel {
  min-height: 374px;
  padding: 30px;
}

.panel h2,
.panel h3 {
  margin: 0 0 16px;
  letter-spacing: -0.055em;
}

.dropzone {
  min-height: 290px;
  border: 2px dashed #b9d8cf;
  border-radius: 24px;
  background: #fbfdfc;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 26px;
  cursor: pointer;
}

.text-tool {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(300px, 0.88fr);
  gap: 18px;
}

.textarea-main {
  width: 100%;
  min-height: 380px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  resize: vertical;
  outline: none;
  line-height: 1.7;
  color: var(--ink);
  background: #fff;
}

.textarea-main:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 4px rgba(8, 125, 100, 0.1);
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.canvas-wrap {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 288px;
  border: 1px dashed #b9d8cf;
  border-radius: 24px;
  background: #fbfdfc;
  overflow: auto;
  padding: 18px;
}

.tool-canvas-wrap {
  width: 100%;
  margin-top: 16px;
  margin-bottom: 20px;
}

.canvas-wrap .placeholder-box {
  width: min(100%, 320px);
  min-height: 118px;
  padding: 18px;
  align-self: center;
  justify-self: center;
}

.canvas-wrap canvas,
.canvas-wrap img {
  max-width: 100%;
  max-height: 420px;
  border-radius: 18px;
}

.mode-row,
.swatch-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.swatch-section {
  margin-top: 2px;
  padding-top: 2px;
}

.swatch-section h3 {
  margin-bottom: 14px;
}

.tool-actions {
  margin-top: 0;
  margin-bottom: 22px;
}

.swatch-row:empty::before {
  content: "이미지를 선택하면 색상 팔레트가 표시됩니다.";
  color: var(--muted);
  font-size: 0.88rem;
}

.mode-btn {
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  color: var(--green-dark);
  font-weight: 900;
  cursor: pointer;
}

.mode-btn.active {
  border-color: var(--green);
  background: var(--mint);
}

.swatch {
  width: 46px;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 16px;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(16, 37, 53, 0.08);
}

.color-preview-dot {
  position: absolute;
  width: 64px;
  height: 64px;
  border: 4px solid #fff;
  border-radius: 999px;
  box-shadow: 0 12px 28px rgba(16, 37, 53, 0.22);
  pointer-events: none;
  transform: translate(-50%, -50%);
}

.dropzone.dragover {
  border-color: var(--green);
  background: var(--mint);
}

.dropzone .big-icon {
  width: 70px;
  height: 70px;
  margin: 0 auto 12px;
  display: grid;
  place-items: center;
  border-radius: 24px;
  background: var(--mint);
  color: var(--green-dark);
  font-size: 1rem;
  font-weight: 900;
}

.small {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.65;
}

.field {
  display: grid;
  gap: 8px;
  margin: 14px 0;
}

.field label {
  font-size: 0.92rem;
  font-weight: 900;
}

.field input[type="number"],
.field select {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0 14px;
  background: white;
  color: var(--ink);
}

.range-row {
  display: grid;
  grid-template-columns: 1fr 96px;
  gap: 10px;
  align-items: center;
}

input[type="range"] {
  width: 100%;
  accent-color: var(--green);
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.option-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 18px;
}

.option-card {
  min-height: 102px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface-soft);
  text-align: left;
  color: inherit;
}

.option-card strong {
  display: block;
  color: var(--green-dark);
  font-size: 0.98rem;
  margin-bottom: 6px;
}

.option-card span {
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.45;
  font-weight: 700;
}

button.option-card {
  cursor: pointer;
}

.quality-card.active {
  border-color: var(--green);
  background: var(--mint);
  box-shadow: 0 10px 24px rgba(8, 125, 100, 0.12);
}

.placeholder-box {
  min-height: 118px;
  display: grid;
  place-items: center;
  border: 1px dashed #b9d8cf;
  border-radius: 22px;
  background: #fbfdfc;
  color: var(--muted);
  text-align: center;
  line-height: 1.6;
  font-weight: 800;
}

.dense-panel {
  display: flex;
  flex-direction: column;
}

.dense-panel .actions {
  margin-top: auto;
}

.result-box {
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 16px;
  background: var(--surface-soft);
}

.result-box span {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
}

.result-box strong {
  display: block;
  margin-top: 6px;
  font-size: 1.4rem;
  color: var(--green-dark);
  letter-spacing: -0.055em;
}

.preview-img,
video {
  width: 100%;
  max-height: 380px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  object-fit: contain;
}

.file-list {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.placeholder-list {
  display: grid;
  gap: 10px;
}

.placeholder-row {
  padding: 14px 16px;
  border-radius: 18px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.55;
}

.file-item {
  display: grid;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 18px;
  background: white;
}

.file-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.feature {
  padding: 26px;
}

.feature h3 {
  margin: 16px 0 8px;
  font-size: 1.18rem;
}

.article-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.article-card {
  padding: 24px;
}

.article-card h3 {
  margin: 0 0 10px;
  font-size: 1.14rem;
}

.guide-list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.7;
}

.callout {
  margin-top: 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface-soft);
  color: var(--muted);
  line-height: 1.65;
}

.site-footer {
  padding: 42px 0 30px;
  border-top: 1px solid var(--line);
  background: #fff;
  color: var(--muted);
  font-size: 0.92rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(360px, max-content);
  gap: 28px 48px;
  align-items: start;
}

.footer-links {
  display: flex;
  justify-content: flex-end;
  gap: 14px;
  flex-wrap: wrap;
  max-width: 620px;
}

.footer-brand {
  display: grid;
  gap: 12px;
}

.footer-logo {
  width: 170px;
  height: auto;
}

.footer-brand p {
  max-width: 520px;
  margin: 0;
  line-height: 1.7;
}

.related-sites {
  display: grid;
  gap: 8px;
  max-width: 260px;
}

.related-sites label {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
}

.related-sites select {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-soft);
  color: var(--ink);
  font-weight: 500;
}

.footer-side {
  display: grid;
  justify-items: end;
  gap: 22px;
  min-width: 0;
}

.footer-copy {
  grid-column: 1 / -1;
  width: 100%;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  justify-self: stretch;
}

.info-layout {
  display: grid;
  gap: 16px;
}

.info-card {
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.info-card h2,
.info-card h3 {
  margin: 0 0 12px;
}

.info-card p,
.info-card li {
  color: var(--muted);
  line-height: 1.75;
}

.info-card ul {
  margin: 0;
  padding-left: 20px;
}

.contact-email {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 14px;
  border-radius: 12px;
  background: var(--mint);
  color: var(--green-dark);
  font-weight: 900;
}

.hidden { display: none !important; }

@media (prefers-reduced-motion: no-preference) {
  .tool-card,
  .btn,
  .button {
    transition: background-color 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
  }
}

@media (max-width: 900px) {
  .hero-grid,
  .tool-layout {
    grid-template-columns: 1fr;
  }

  .tool-grid,
  .tool-grid.two-tools,
  .tool-grid.five-tools,
  .feature-grid,
  .article-grid,
  .info-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .section-head p,
  .section-title p {
    margin-top: 0;
  }

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

  .footer-side {
    justify-items: start;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

@media (max-width: 820px) {
  .container {
    width: min(100% - 32px, 560px);
  }

  .header-row,
  .nav {
    min-height: 0;
    padding: 12px 0 10px;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .nav-links {
    justify-content: flex-start;
    gap: 14px;
    overflow-x: auto;
    white-space: nowrap;
    font-size: 0.88rem;
    scrollbar-width: none;
    flex-wrap: nowrap;
  }
}

@media (max-width: 640px) {
  .hero { padding: 42px 0 38px; }
  .page-hero { padding: 40px 0 28px; }
  .tool-grid,
  .tool-grid.two-tools,
  .tool-grid.five-tools,
  .feature-grid,
  .article-grid,
  .info-grid,
  .result-grid {
    grid-template-columns: 1fr;
  }
  .range-row { grid-template-columns: 1fr; }
  .option-grid { grid-template-columns: 1fr; }
  .text-tool { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: 1fr; }
  .button-row .btn,
  .actions .btn { width: 100%; }
  .footer-grid { align-items: flex-start; flex-direction: column; }
}
