:root {
  --bg: #f1efe9;
  --ink: #171410;
  --muted: #5f5a50;
  --accent: #26588b;
  --accent-dark: #1b385f;
  --accent-2: #f2c26f;
  --accent-3: #2d6fb8;
  --panel: rgba(255, 255, 255, 0.78);
  --border: rgba(19, 17, 15, 0.16);
  --shadow: 0 30px 60px rgba(19, 16, 12, 0.15);
  --paper-base: #fff9f0;
  --paper-line: rgba(160, 120, 90, 0.12);
  --ink-soft: rgba(23, 20, 16, 0.7);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Gothic A1", "Nanum Myeongjo", serif;
  color: var(--ink);
  background: radial-gradient(circle at 10% 15%, rgba(242, 194, 111, 0.35) 0%, transparent 50%),
    radial-gradient(circle at 75% 5%, rgba(45, 111, 184, 0.25) 0%, transparent 40%),
    radial-gradient(circle at 85% 85%, rgba(38, 88, 139, 0.2) 0%, transparent 45%),
    linear-gradient(120deg, #f9f3ea 0%, #eef3f9 55%, #f2ede6 100%);
  min-height: 100vh;
  padding: 52px clamp(20px, 5vw, 96px) 72px;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    radial-gradient(circle at 15% 20%, rgba(255, 255, 255, 0.35), transparent 55%),
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.3) 0,
      rgba(255, 255, 255, 0.3) 1px,
      transparent 1px,
      transparent 120px
    );
  opacity: 0.55;
  pointer-events: none;
  z-index: 0;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 80% 40%, rgba(255, 255, 255, 0.35), transparent 60%);
  opacity: 0.5;
  pointer-events: none;
  z-index: 0;
}

.site-banner {
  position: relative;
  z-index: 1;
  margin: -12px auto 16px;
  max-width: 600px;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 26px 60px rgba(10, 18, 40, 0.22);
  border: 1px solid rgba(9, 15, 30, 0.08);
}

.site-banner img {
  display: block;
  width: 100%;
  height: auto;
}

.bg-orb {
  position: absolute;
  border-radius: 999px;
  filter: blur(12px);
  opacity: 0.2;
  z-index: 0;
}

.orb-a {
  width: 460px;
  height: 240px;
  background: linear-gradient(140deg, rgba(38, 88, 139, 0.65), rgba(242, 194, 111, 0.35));
  top: -110px;
  right: -120px;
  transform: rotate(-8deg);
}

.orb-b {
  width: 320px;
  height: 280px;
  background: linear-gradient(200deg, rgba(45, 111, 184, 0.6), rgba(246, 222, 176, 0.25));
  bottom: -140px;
  left: -120px;
  transform: rotate(16deg);
}

.site-header {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 36px;
  animation: fadeIn 0.8s ease-out;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  gap: 22px;
  align-items: flex-start;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.brand-mark {
  font-family: "Nanum Myeongjo", serif;
  font-size: 30px;
  font-weight: 700;
  padding: 14px 22px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.85);
  box-shadow: 0 12px 28px rgba(19, 16, 12, 0.12);
}

.site-header h1 {
  margin: 0;
  font-family: "Nanum Myeongjo", serif;
  font-size: clamp(28px, 3.4vw, 40px);
  letter-spacing: -0.02em;
}

.site-header p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.badge {
  background: rgba(255, 255, 255, 0.85);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 12px;
  border: 1px solid rgba(19, 16, 12, 0.12);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.header-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.top-nav {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 14px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.top-nav a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  padding-bottom: 4px;
}

.top-nav a:hover {
  border-bottom-color: var(--accent);
}

.layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(320px, 1.2fr) minmax(320px, 0.8fr) minmax(240px, 0.45fr);
  gap: 28px;
  align-items: start;
  animation: slideUp 0.8s ease-out 0.1s both;
}

.content-section {
  position: relative;
  z-index: 1;
  margin: 48px 0;
  padding: 32px;
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 250, 244, 0.88));
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.content-section.alt {
  background: rgba(255, 248, 235, 0.9);
}

.section-header {
  margin-bottom: 20px;
}

.section-header h2 {
  margin: 0 0 8px;
  font-size: clamp(20px, 2.4vw, 28px);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

.info-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(27, 27, 27, 0.08);
  border-radius: 20px;
  padding: 20px;
  box-shadow: 0 20px 40px rgba(17, 15, 12, 0.08);
  transform: translateY(0);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.info-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 30px 50px rgba(17, 15, 12, 0.14);
}

.info-card h3 {
  margin-top: 0;
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  color: var(--accent-dark);
  text-decoration: none;
  font-weight: 700;
}

.card-link::after {
  content: "→";
  font-size: 12px;
}

.steps {
  margin: 0;
  padding-left: 20px;
  line-height: 1.8;
}

.faq details {
  border: 1px solid rgba(27, 27, 27, 0.12);
  border-radius: 18px;
  padding: 14px 18px;
  margin-bottom: 12px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 16px 26px rgba(17, 15, 12, 0.08);
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
}

.panel {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 248, 240, 0.88));
  border: 1px solid rgba(19, 16, 12, 0.12);
  border-radius: 28px;
  padding: 30px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.panel h2 {
  margin-top: 0;
  font-size: 20px;
}

.field {
  margin-bottom: 18px;
}

label {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 8px;
  color: var(--muted);
}

input,
select,
textarea {
  width: 100%;
  border-radius: 16px;
  border: 1px solid rgba(27, 27, 27, 0.12);
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.95);
  font-size: 14px;
  font-family: inherit;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: rgba(38, 88, 139, 0.5);
  box-shadow: 0 0 0 3px rgba(38, 88, 139, 0.12);
}

textarea {
  resize: vertical;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
}

.suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.suggestion {
  border: 1px solid rgba(27, 27, 27, 0.12);
  border-radius: 999px;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.8);
  cursor: pointer;
  transition: transform 0.2s ease, border 0.2s ease, box-shadow 0.2s ease;
}

.suggestion:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 10px 18px rgba(38, 88, 139, 0.18);
}

.hint {
  font-size: 12px;
  color: var(--muted);
  margin: 10px 0 0;
}

.template-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
  max-height: 220px;
  overflow: auto;
  padding-right: 6px;
}

.template-chip {
  border: 1px solid rgba(27, 27, 27, 0.12);
  border-radius: 999px;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.85);
  cursor: pointer;
  font-size: 12px;
  transition: transform 0.2s ease, border 0.2s ease, box-shadow 0.2s ease;
}

.template-chip:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 10px 18px rgba(38, 88, 139, 0.18);
}

.output-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.status {
  margin: 12px 0 0;
  font-size: 13px;
  color: var(--muted);
}

.autosave {
  margin: 0 0 16px;
  font-size: 12px;
  color: var(--ink-soft);
  letter-spacing: 0.03em;
}

.draft-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
  padding: 14px 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px dashed rgba(19, 16, 12, 0.2);
  box-shadow: 0 16px 30px rgba(17, 14, 10, 0.08);
}

.draft-banner p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.site-footer {
  position: relative;
  z-index: 1;
  margin-top: 60px;
  padding: 32px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  align-items: center;
}

.site-footer.compact {
  margin: 40px clamp(20px, 4vw, 80px);
}

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

.footer-links a {
  color: var(--ink);
  text-decoration: none;
}

.page {
  padding: 32px clamp(20px, 4vw, 80px) 64px;
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

.page-hero {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 22px;
  padding: 26px 30px;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.page-hero h1 {
  margin: 0 0 8px;
  font-family: "Nanum Myeongjo", serif;
  font-size: clamp(26px, 3vw, 34px);
}

.page-hero p {
  margin: 0;
  color: var(--muted);
  max-width: 520px;
}

.page-content {
  position: relative;
  z-index: 1;
}

.article {
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 28px;
  box-shadow: var(--shadow);
  line-height: 1.8;
}

.article h1 {
  margin-top: 0;
}

.button-link {
  display: inline-block;
  margin-top: 16px;
  background: var(--accent);
  color: #fff;
  padding: 10px 18px;
  border-radius: 999px;
  text-decoration: none;
}

.contact-form {
  display: grid;
  gap: 14px;
  margin: 18px 0;
}

.contact-form label {
  text-transform: none;
  letter-spacing: normal;
  font-size: 14px;
}

.paper {
  margin-top: 18px;
  background:
    repeating-linear-gradient(
      180deg,
      transparent 0,
      transparent 26px,
      var(--paper-line) 26px,
      var(--paper-line) 27px
    ),
    linear-gradient(180deg, var(--paper-base) 0%, #fff3e6 100%);
  border-radius: 24px;
  border: 1px dashed rgba(27, 27, 27, 0.22);
  padding: 24px;
  min-height: 420px;
  font-family: "Nanum Myeongjo", serif;
  white-space: pre-wrap;
  line-height: 1.7;
}

.placeholder {
  color: var(--muted);
}

button {
  border: none;
  border-radius: 14px;
  padding: 10px 18px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

button:hover {
  transform: translateY(-2px);
}

.primary {
  background: linear-gradient(130deg, #26588b 0%, #2d6fb8 100%);
  color: #fff;
  box-shadow: 0 14px 28px rgba(38, 88, 139, 0.28);
}

.secondary {
  background: #1b1a18;
  color: #fff;
  box-shadow: 0 14px 22px rgba(27, 26, 24, 0.25);
}

.ghost {
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid var(--border);
}

.output-stats {
  display: flex;
  gap: 14px;
  margin-top: 10px;
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.side-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: sticky;
  top: 32px;
}

.side-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(27, 27, 27, 0.08);
  border-radius: 20px;
  padding: 18px;
  box-shadow: 0 16px 30px rgba(17, 15, 12, 0.08);
  display: grid;
  gap: 12px;
}

.side-card h3 {
  margin: 0;
  font-size: 15px;
}

.side-label {
  margin: 0;
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--muted);
}

.side-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
  font-size: 13px;
}

.side-list li {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: var(--ink);
  cursor: pointer;
}

.side-list span {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.08em;
}

.ad-card {
  align-items: center;
}

.side-card button {
  width: 100%;
}

@keyframes floatIn {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.content-section,
.panel,
.info-card,
.page-hero {
  animation: floatIn 0.9s ease both;
}

.content-section:nth-of-type(2) {
  animation-delay: 0.1s;
}

.content-section:nth-of-type(3) {
  animation-delay: 0.2s;
}

.content-section:nth-of-type(4) {
  animation-delay: 0.3s;
}

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

  .site-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-actions {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .page-hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .side-panel {
    position: static;
  }
}

@media (max-width: 700px) {
  body {
    padding: 36px 18px 56px;
  }

  .top-nav {
    width: 100%;
    justify-content: flex-start;
  }

  .brand {
    align-items: center;
  }

  .brand-mark {
    border-radius: 14px;
  }

  .draft-banner {
    flex-direction: column;
    align-items: flex-start;
  }

  .banner-actions {
    width: 100%;
  }
}
