:root {
  --bg: #f7faf8;
  --surface: #ffffff;
  --surface-soft: #eef7f4;
  --ink: #17211f;
  --muted: #62706c;
  --line: #dce8e3;
  --brand: #0f766e;
  --brand-dark: #134e4a;
  --accent: #eab308;
  --danger: #c2410c;
  --shadow: 0 22px 60px rgba(19, 78, 74, 0.12);
  --radius: 8px;
  font-family:
    Inter, Pretendard, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: 14px clamp(20px, 5vw, 72px);
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid rgba(220, 232, 227, 0.7);
  box-shadow: 0 10px 30px rgba(19, 78, 74, 0.05);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 11px;
  color: var(--ink);
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  color: #fff;
  background: var(--brand);
  border-radius: 50%;
  box-shadow: inset 0 -10px 18px rgba(19, 78, 74, 0.18);
  font-size: 0.72rem;
  font-weight: 900;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.nav a {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  padding: 0 11px;
  border-radius: 999px;
  white-space: nowrap;
}

.nav a:hover {
  color: var(--brand-dark);
  background: var(--surface-soft);
}

.section-band,
.content-section,
.calculator-section {
  padding: clamp(56px, 8vw, 96px) clamp(20px, 5vw, 72px);
}

.hero,
.home-hero {
  display: grid;
  min-height: calc(100vh - 67px);
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  align-items: center;
  gap: clamp(32px, 6vw, 78px);
  padding-top: clamp(40px, 7vw, 88px);
}

.home-hero {
  min-height: min(760px, calc(100vh - 67px));
}

.page-hero {
  background:
    linear-gradient(135deg, rgba(15, 118, 110, 0.09), rgba(234, 179, 8, 0.08)),
    #fff;
}

.compact-hero {
  min-height: auto;
  padding-bottom: clamp(44px, 6vw, 72px);
}

.page-hero + .calculator-section {
  padding-top: clamp(34px, 5vw, 56px);
}

.page-hero + .calculator-section > .section-heading {
  display: none;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--brand);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  word-break: keep-all;
  overflow-wrap: break-word;
}

h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2.35rem, 5vw, 5.2rem);
  line-height: 1.04;
}

h2 {
  margin: 0;
  font-size: clamp(1.8rem, 3.5vw, 3rem);
  line-height: 1.15;
}

h3 {
  margin: 0 0 8px;
  font-size: 1.08rem;
}

.hero-text,
.section-heading p {
  max-width: 760px;
  color: var(--muted);
  font-size: 1.04rem;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.breadcrumbs a {
  color: var(--brand-dark);
}

.nowrap {
  white-space: nowrap;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-weight: 800;
}

.button.primary {
  color: #fff;
  background: var(--brand);
  border-color: var(--brand);
}

.button.ghost {
  background: #fff;
}

.hero-visual {
  display: grid;
  min-height: 420px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(15, 118, 110, 0.14), rgba(234, 179, 8, 0.12)),
    radial-gradient(circle at 78% 20%, rgba(15, 118, 110, 0.18), transparent 28%),
    #fff;
  box-shadow: var(--shadow);
}

.home-summary {
  display: grid;
  gap: 14px;
}

.summary-card,
.home-stat-grid p {
  margin: 0;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}

.summary-card.highlight {
  color: #fff;
  background:
    linear-gradient(135deg, rgba(15, 118, 110, 0.96), rgba(19, 78, 74, 0.96)),
    var(--brand-dark);
  border-color: transparent;
}

.summary-card span,
.home-stat-grid span {
  display: block;
  color: inherit;
  opacity: 0.72;
  font-size: 0.86rem;
  font-weight: 800;
}

.summary-card strong,
.home-stat-grid strong {
  display: block;
  margin-top: 5px;
  font-size: clamp(1.25rem, 2.4vw, 1.8rem);
  line-height: 1.2;
}

.summary-card p {
  margin: 12px 0 0;
}

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

.dashboard-mini {
  width: min(420px, 86%);
  padding: 26px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.dashboard-mini span,
.metric-grid span,
.comparison-bars span,
.feature-list span {
  display: block;
  color: var(--muted);
  font-size: 0.86rem;
}

.dashboard-mini strong {
  display: block;
  margin-top: 4px;
  font-size: 1.35rem;
}

.mini-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 22px;
}

.mini-grid p,
.metric-grid article,
.info-grid article,
.feature-list article {
  margin: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.section-heading {
  max-width: 920px;
  margin-bottom: 32px;
}

.calculator-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(340px, 1.1fr);
  gap: 22px;
  align-items: start;
}

.calc-panel,
.result-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.calc-panel {
  display: grid;
  gap: 18px;
  padding: 22px;
}

fieldset {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0 0 18px;
  border: 0;
  border-bottom: 1px solid var(--line);
}

fieldset:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

legend {
  margin-bottom: 10px;
  font-weight: 800;
}

label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.amount-hint {
  flex: 0 0 auto;
  padding-left: 8px;
  padding-right: 12px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
}

.input-wrap {
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

input {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 0 12px;
  color: var(--ink);
  background: transparent;
  border: 0;
  font: inherit;
  font-weight: 800;
}

input:focus {
  outline: 2px solid rgba(15, 118, 110, 0.28);
  outline-offset: 2px;
}

.input-wrap b {
  flex: 0 0 auto;
  padding-right: 12px;
  padding-left: 2px;
  color: var(--muted);
  font-size: 0.84rem;
  white-space: nowrap;
}

.input-wrap.has-amount-hint b {
  display: none;
}

.result-panel {
  position: sticky;
  top: 88px;
  padding: 24px;
}

.result-hero {
  padding: 22px;
  border-radius: var(--radius);
  background: var(--surface-soft);
}

.result-hero span {
  display: inline-flex;
  margin-bottom: 12px;
  padding: 5px 10px;
  color: var(--brand-dark);
  background: #fff;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 900;
}

.result-hero h3 {
  font-size: clamp(1.45rem, 3vw, 2.4rem);
  line-height: 1.14;
}

.result-hero p {
  margin-bottom: 0;
  color: var(--muted);
}

.metric-grid,
.info-grid,
.feature-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.metric-grid strong {
  display: block;
  margin-top: 6px;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
}

.comparison-bars {
  display: grid;
  gap: 18px;
  margin-top: 22px;
}

.comparison-bars div {
  display: grid;
  gap: 6px;
}

.comparison-bars b {
  font-size: 0.95rem;
}

.comparison-bars i {
  display: block;
  width: 0;
  height: 12px;
  background: var(--brand);
  border-radius: 999px;
  transition: width 0.25s ease;
}

.comparison-bars div:first-child i {
  background: var(--danger);
}

.content-section {
  background: #fff;
}

.content-section.muted,
.calculator-section.muted {
  background: var(--surface-soft);
}

.info-grid,
.feature-list {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

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

.tool-card {
  display: grid;
  align-content: start;
  min-height: 260px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 14px 40px rgba(19, 78, 74, 0.07);
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.2s ease;
}

.tool-card:hover {
  border-color: rgba(15, 118, 110, 0.45);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.tool-eyebrow {
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 900;
}

.tool-card h3 {
  margin-top: 8px;
  font-size: 1.28rem;
  line-height: 1.25;
}

.tool-card p {
  margin: 8px 0 0;
  color: var(--muted);
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 18px;
}

.tag-row span {
  padding: 5px 8px;
  color: var(--brand-dark);
  background: var(--surface-soft);
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
}

.compact-tools .tool-card {
  min-height: 220px;
}

.faq-hero {
  padding-top: clamp(24px, 3vw, 40px);
  padding-bottom: clamp(24px, 3vw, 38px);
}

.faq-hero-inner {
  max-width: 1120px;
  margin: 0 auto;
}

.faq-hero h1 {
  font-size: clamp(2rem, 2.65vw, 2.75rem);
  line-height: 1.12;
}

.faq-hero .hero-text {
  max-width: 560px;
}

.faq-section {
  padding-top: clamp(24px, 3vw, 38px);
}

.faq-shell {
  display: grid;
  grid-template-columns: minmax(240px, 0.42fr) minmax(420px, 0.78fr);
  max-width: 1120px;
  margin: 0 auto;
  gap: 36px;
  align-items: start;
}

.faq-intro {
  position: sticky;
  top: 96px;
}

.faq-intro h2 {
  font-size: clamp(1.6rem, 2.4vw, 2.35rem);
}

.faq-intro p {
  max-width: 340px;
  color: var(--muted);
}

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

.faq-list details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 14px 36px rgba(19, 78, 74, 0.06);
}

.faq-list summary {
  cursor: pointer;
  padding: 18px 20px;
  color: var(--ink);
  font-weight: 900;
  list-style: none;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "+";
  float: right;
  color: var(--brand);
  font-weight: 900;
}

.faq-list details[open] summary::after {
  content: "-";
}

.faq-list p {
  margin: 0;
  padding: 0 20px 20px;
  color: var(--muted);
}

.nav a[aria-current="page"] {
  color: #fff;
  background: var(--brand);
}

.feature-list article span {
  color: var(--accent);
  font-weight: 900;
}

.loan-summary-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

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

.loan-summary-strip div,
.scenario-grid article {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.loan-summary-strip span,
.scenario-grid span {
  display: block;
  color: var(--muted);
  font-size: 0.86rem;
}

.loan-summary-strip strong,
.scenario-grid strong {
  display: block;
  margin-top: 6px;
  font-size: 1.2rem;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 26px clamp(20px, 5vw, 72px);
  color: var(--muted);
  background: #101a18;
}

.site-footer a {
  color: #fff;
  font-weight: 800;
}

.footer-links {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 14px;
}

@media (max-width: 900px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .nav {
    width: 100%;
    flex-wrap: nowrap;
    justify-content: flex-start;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .nav::-webkit-scrollbar {
    display: none;
  }

  .hero,
  .home-hero,
  .calculator-layout,
  .info-grid,
  .feature-list,
  .tool-grid,
  .faq-shell {
    grid-template-columns: 1fr;
  }

  .hero,
  .home-hero {
    min-height: auto;
  }

  .result-panel {
    position: static;
  }

  .faq-intro {
    position: static;
  }

  .faq-intro p {
    max-width: 680px;
  }
}

@media (max-width: 560px) {
  .section-band,
  .content-section,
  .calculator-section {
    padding: 34px 16px;
  }

  .site-header {
    gap: 10px;
    padding: 12px 16px;
  }

  .brand {
    gap: 9px;
    font-size: 0.96rem;
  }

  .brand-mark {
    width: 32px;
    height: 32px;
    font-size: 0.66rem;
  }

  .nav {
    gap: 5px;
    font-size: 0.8rem;
  }

  .nav a {
    min-height: 30px;
    padding: 0 8px;
  }

  .compact-hero {
    padding-top: 30px;
    padding-bottom: 22px;
  }

  .faq-hero h1 {
    font-size: 1.9rem;
  }

  .faq-section {
    padding-top: 28px;
  }

  .faq-shell {
    gap: 20px;
  }

  .faq-intro h2 {
    font-size: 1.35rem;
  }

  .page-hero + .calculator-section {
    padding-top: 20px;
  }

  .eyebrow {
    margin-bottom: 8px;
    font-size: 0.7rem;
  }

  h1 {
    font-size: 1.75rem;
    line-height: 1.16;
  }

  h2 {
    font-size: 1.45rem;
    line-height: 1.22;
  }

  h3 {
    font-size: 1rem;
  }

  .hero-text,
  .section-heading p,
  .tool-card p,
  .result-hero p {
    font-size: 0.94rem;
    line-height: 1.58;
  }

  .breadcrumbs {
    margin-bottom: 14px;
    font-size: 0.78rem;
  }

  .section-heading {
    margin-bottom: 22px;
  }

  .hero-actions,
  .button {
    width: 100%;
  }

  .button {
    min-height: 42px;
    font-size: 0.92rem;
  }

  .summary-card,
  .home-stat-grid p,
  .tool-card,
  .calc-panel,
  .result-panel {
    padding: 18px;
  }

  .tool-card {
    min-height: auto;
  }

  .tool-card h3 {
    font-size: 1.1rem;
  }

  .faq-list summary {
    padding: 16px;
    font-size: 0.94rem;
  }

  .faq-list p {
    padding: 0 16px 16px;
    font-size: 0.9rem;
  }

  .summary-card strong,
  .home-stat-grid strong {
    font-size: 1.18rem;
  }

  legend {
    font-size: 0.95rem;
  }

  label {
    font-size: 0.86rem;
  }

  .mini-grid,
  .metric-grid,
  .home-stat-grid,
  .loan-summary-strip,
  .scenario-grid {
    grid-template-columns: 1fr;
  }

  input {
    min-height: 42px;
    font-size: 0.9rem;
  }

  .amount-hint {
    font-size: 0.74rem;
    padding-left: 6px;
  }

  .input-wrap b {
    font-size: 0.78rem;
  }

  .result-hero {
    padding: 18px;
  }

  .result-hero span {
    margin-bottom: 10px;
    font-size: 0.7rem;
  }

  .result-hero h3 {
    font-size: 1.32rem;
    line-height: 1.22;
  }

  .metric-grid article,
  .info-grid article,
  .loan-summary-strip div,
  .scenario-grid article {
    padding: 16px;
  }

  .metric-grid span,
  .loan-summary-strip span,
  .scenario-grid span {
    font-size: 0.78rem;
  }

  .metric-grid strong,
  .loan-summary-strip strong,
  .scenario-grid strong {
    font-size: 1.05rem;
  }

  .hero-visual {
    min-height: 330px;
  }
}
