@import url('https://fonts.googleapis.com/css2?family=Gloock&family=IBM+Plex+Sans+KR:wght@300;400;600&display=swap');

:root {
  color-scheme: light;
  --ink: #0f1216;
  --muted: #5c6670;
  --brand: #ff6a3d;
  --brand-deep: #d94b28;
  --mint: #38d6b4;
  --sky: #6aa7ff;
  --gold: #f4c24b;
  --bg: #f8f4ee;
  --card: #ffffff;
  --stroke: #e8dfd3;
  --shadow: 0 30px 80px rgba(16, 23, 34, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'IBM Plex Sans KR', sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at top, #fff5e8 0%, var(--bg) 40%, #f3efe8 100%);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

.bg-orb {
  position: fixed;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  filter: blur(0px);
  opacity: 0.35;
  z-index: 0;
}

.orb-a {
  background: radial-gradient(circle at 30% 30%, #ffd28a, transparent 70%);
  top: -80px;
  left: -40px;
}

.orb-b {
  background: radial-gradient(circle at 70% 40%, #7de4ff, transparent 70%);
  bottom: -120px;
  right: -60px;
}

.bg-grid {
  position: fixed;
  inset: 0;
  background-image: linear-gradient(transparent 94%, rgba(0, 0, 0, 0.03) 95%),
    linear-gradient(90deg, transparent 94%, rgba(0, 0, 0, 0.03) 95%);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 0;
}

.site-header {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 8vw;
}

.logo {
  font-family: 'Gloock', serif;
  font-size: 28px;
  letter-spacing: 2px;
}

.nav {
  display: flex;
  gap: 12px;
}

.pill {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 10px 18px;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 12px 30px rgba(16, 23, 34, 0.08);
}

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

.container {
  position: relative;
  z-index: 1;
  padding: 0 8vw 80px;
}

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 36px;
  align-items: center;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 12px;
}

h1 {
  font-family: 'Gloock', serif;
  font-size: clamp(32px, 4vw, 56px);
  margin: 0 0 16px;
}

.lead {
  font-size: 18px;
  color: var(--muted);
  max-width: 480px;
}

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

.cta {
  border: 0;
  border-radius: 12px;
  padding: 12px 18px;
  font-weight: 600;
  cursor: pointer;
  background: var(--brand);
  color: #fff;
  box-shadow: 0 12px 30px rgba(217, 75, 40, 0.2);
}

.cta.ghost {
  background: var(--card);
  color: var(--ink);
  border: 1px solid var(--stroke);
  box-shadow: 0 12px 30px rgba(16, 23, 34, 0.08);
}

.hero-card {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 24px;
  padding: 28px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.hero-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(255, 106, 61, 0.08), transparent);
  pointer-events: none;
}

.hero-label {
  display: inline-flex;
  background: var(--brand);
  color: white;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: 1px;
}

.draw-meta {
  display: flex;
  justify-content: space-between;
  margin: 18px 0 16px;
  font-weight: 600;
}

.numbers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(48px, 1fr));
  gap: 12px;
  align-items: center;
}

.ball {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 16px;
  font-weight: 600;
  font-size: 18px;
  color: var(--ink);
  background: #f5f1ea;
  border: 1px solid #e6dccf;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.ball.bonus {
  background: var(--brand);
  color: white;
  border: none;
}

body.show-ranges .ball.range-1 {
  background: #fff2ce;
}

body.show-ranges .ball.range-2 {
  background: #e4f7ff;
}

body.show-ranges .ball.range-3 {
  background: #e8f6e9;
}

body.show-ranges .ball.range-4 {
  background: #f2e9ff;
}

body.show-ranges .ball.range-5 {
  background: #ffe5e0;
}

.note {
  margin-top: 12px;
  font-size: 12px;
  color: var(--muted);
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin: 40px 0;
}

.stat-card {
  background: var(--card);
  border-radius: 18px;
  padding: 20px;
  border: 1px solid var(--stroke);
  box-shadow: 0 20px 50px rgba(16, 23, 34, 0.08);
}

.archive {
  margin-top: 24px;
}

.section-title {
  display: flex;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 20px;
}

.section-title h2 {
  font-family: 'Gloock', serif;
  font-size: 28px;
  margin: 0;
}

.section-title p {
  color: var(--muted);
  margin: 0;
}

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

.draw-card {
  background: var(--card);
  border-radius: 18px;
  padding: 18px;
  border: 1px solid var(--stroke);
  box-shadow: 0 20px 50px rgba(16, 23, 34, 0.06);
}

.draw-head {
  display: flex;
  justify-content: space-between;
  font-weight: 600;
  margin-bottom: 12px;
}

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

.contact-section {
  margin-top: 40px;
}

.contact-form {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 18px;
  box-shadow: 0 20px 50px rgba(16, 23, 34, 0.08);
  padding: 24px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

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

.field span {
  font-size: 13px;
  color: var(--muted);
}

.field input,
.field textarea {
  font: inherit;
  border: 1px solid var(--stroke);
  border-radius: 10px;
  padding: 10px 12px;
  background: #fffdfa;
}

.field textarea {
  resize: vertical;
  min-height: 120px;
}

.field-full {
  grid-column: 1 / -1;
}

.contact-form .cta {
  width: fit-content;
}

.form-message {
  margin: 0;
  font-size: 14px;
  align-self: center;
}

.form-message.success {
  color: #177a4b;
}

.form-message.error {
  color: #b02b1e;
}

.site-footer {
  text-align: center;
  padding: 30px 0 40px;
  color: var(--muted);
  font-size: 13px;
  position: relative;
  z-index: 1;
}

.reveal {
  animation: rise 0.6s ease forwards;
  opacity: 0;
  transform: translateY(16px);
}

@keyframes rise {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

  .nav {
    width: 100%;
    flex-wrap: wrap;
  }

  .numbers {
    grid-template-columns: repeat(auto-fit, minmax(44px, 1fr));
  }

  .contact-form {
    grid-template-columns: 1fr;
  }
}
