body {
  min-height: 100vh;
  overflow: hidden;
  padding: 2rem;
}
.topbar {
  position: relative;
  z-index: 5;
}
.wrapper {
  position: relative;
  z-index: 2;
  height: calc(100vh - 90px);
  display: grid;
  grid-template-columns: 0.85fr 1.2fr;
  gap: 2rem;
  align-items: center;
}
.hero h1 {
  margin-top: 1rem;
  font-size: clamp(4rem, 9vw, 7rem);
  line-height: 0.88;
  letter-spacing: -0.08em;
}
.hero p {
  margin-top: 2rem;
  max-width: 460px;
  line-height: 1.9;
  color: var(--muted);
}
.controls {
  margin-top: 2rem;
  display: flex;
  gap: 1rem;
}
input[type="color"] {
  width: 70px;
  height: 58px;
  border: none;
  background: none;
  cursor: pointer;
}
input[type="color"]::-webkit-color-swatch {
  border: none;
  border-radius: 18px;
}
#hexInput {
  flex: 1;
  height: 58px;
  border: none;
  outline: none;
  padding: 0 1rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--border);
}
#generateBtn {
  height: 58px;
  padding: 0 1.4rem;
  border: none;
  border-radius: 18px;
  background: #111;
  color: #fff;
  font-weight: 600;
}
.preset-row {
  margin-top: 1.5rem;
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
}
.preset {
  width: 42px;
  height: 42px;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  transition: var(--transition);
}
.preset:hover {
  transform: scale(1.08);
}
.studio {
  height: 88%;
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(24px);
}
.palette-grid {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
}
.palette-card {
  border-radius: 28px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border-light);
  background: rgba(255, 255, 255, 0.7);
}
.palette-color {
  flex: 1;
}
.palette-info {
  padding: 1rem;
  background: rgba(255, 255, 255, 0.88);
}
.palette-info button {
  width: 100%;
  height: 44px;
  border: none;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.05);
  font-weight: 600;
  letter-spacing: 0.04em;
}
.bottom-grid {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.info-card {
  padding: 1.2rem;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--border-light);
}
.info-list {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.info-list div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}
.info-list span {
  color: var(--muted);
}
.style-grid {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.8rem;
}
.style-btn {
  height: 48px;
  border: none;
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.05);
  transition: var(--transition);
}
.style-btn.active {
  background: #111;
  color: #fff;
}
.copied {
  background: rgba(34, 197, 94, 0.12) !important;
}

@media (max-width: 1100px) {
  body {
    overflow: auto;
    padding: 1.25rem;
  }
  .wrapper {
    grid-template-columns: 1fr;
    height: auto;
    padding-bottom: 2rem;
  }
  .hero h1 {
    font-size: clamp(3rem, 14vw, 5rem);
  }
  .studio {
    height: auto;
  }
  .palette-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .palette-color {
    min-height: 180px;
  }
}

@media (max-width: 640px) {
  .controls {
    flex-direction: column;
  }
  .palette-grid {
    grid-template-columns: 1fr;
  }
  .bottom-grid {
    grid-template-columns: 1fr;
  }
}
