:root {
  --color-dot-red: #ff5f57;
  --color-dot-yellow: #febc2e;
  --color-dot-green: #28c840;

  --color-background: #1b1b20;
  --color-woowahan2: #0cefd3;
  --color-woowahan: #2ac1bc;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--color-background);
  font-family: "Pretendard Variable", Pretendard, system-ui, sans-serif;
  color: #e2e8f0;
}
a {
  color: rgb(122, 122, 246);
}

p,
h1 {
  white-space: pre-line;
}

li {
  margin-top: 4px;
}
#app {
  min-height: 100vh;
}

/* header */ /* header */
#guide-header {
  z-index: 100;
  position: fixed;
  top: 0;
  padding: 10px 16px;
  background: transparent;
}

.header-inputs {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
}

.header-inputs input,
select {
  width: 100%;
  min-width: 0;
  height: 42px; /* 터치하기 좋게 살짝 높임 */
  padding: 10px 14px;
  font-size: 16px;
  color: #ffffff;

  /* 리퀴드 글래스 인풋 스타일 */
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(1px) saturate(160%);
  -webkit-backdrop-filter: blur(1px) saturate(160%);

  /* 유리 질감 테두리 */
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;

  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.header-inputs input:focus {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--color-woowahan2);
  outline: none;
}

/* 플레이스홀더 색상도 유리 느낌에 맞게 조절 */
.header-inputs input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.header-inputs #input-repo {
  grid-column: 1 / -1;
}
/* scroll-bar */
::-webkit-scrollbar {
  width: 4px;
  height: 3px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: #334155;
  border-radius: 10px;
}

/* Card */
.card {
  min-height: 25vh;
  padding: 20px 20px;
  display: flex;
  flex-direction: column;
  margin-bottom: 40px;
  gap: 50px;
}

.card-title {
  font-size: 2vh;
  font-weight: 700;
  color: #f1f5f9;
}

.card-desc {
  font-size: 2vh;
  color: #94a3b8;
  line-height: 1.7;
}

#card-container {
  background-color: #1b1b20;
  flex: 2;
  overflow-y: auto;
  min-height: 0;
}
/* shiki 코드블럭 */
.visual-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.code-wrapper {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
}

.code-wrapper pre {
  margin: 0;
  padding: 16px;
  padding-right: 52px;
  overflow-x: auto;
  white-space: pre;
}

/* code-copy-btn */
.copy-btn {
  position: absolute;
  top: 6px;
  right: 6px;
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.4);
  border-radius: 6px;
  padding: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
}

.copy-btn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.copy-btn svg {
  width: 16px;
  height: 16px;
}

/* 맥 창 */
.mac-window {
  background: #1e1e2e;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  width: 85%;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.window-bar {
  background: #2a2a3c;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(0, 0, 0, 0.2);
}

.window-dots {
  display: flex;
  align-items: center;
  gap: 6px;
}

.window-dots-placeholder {
  width: 46px;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.dot.red {
  background: var(--color-dot-red);
}
.dot.yellow {
  background: var(--color-dot-yellow);
}
.dot.green {
  background: var(--color-dot-green);
}

.window-title {
  font-size: 14px;
  color: #94a3b8;
  background: #1e1e2e;
  padding: 2px 24px;
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.window-body {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  min-height: 300px;
  transition: all 2s ease;
}

.window-body img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 4px;
}

/* alert */
.card-alert {
  margin-top: 20px;
  padding: 6px 2px 6px 16px;
  border-left: 4px solid;
  background: rgba(15, 23, 42, 0.72);
  border-radius: 0 12px 12px 0;
}

.card-alert-header {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 6px;
}

.card-alert-icon {
  font-size: 0.8rem;
}

.card-alert-title {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.card-alert-message {
  color: #989fac;
  font-size: 0.8rem;
  line-height: 1.4;
}

.card-alert-note,
.card-alert-note .card-alert-icon,
.card-alert-note .card-alert-title {
  color: #60a5fa;
}

.card-alert-warning,
.card-alert-warning .card-alert-icon,
.card-alert-warning .card-alert-title {
  color: #ff4f42;
}

/* 블러 배경 */
.blur-bg {
  position: absolute;
  width: 50%;
  height: 50%;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}

.blur-top {
  top: -10%;
  left: -10%;
  background: rgba(37, 99, 235, 0.2);
  filter: blur(150px);
}

.blur-bottom {
  bottom: -10%;
  right: -10%;
  background: rgba(0, 219, 190, 0.757);
  filter: blur(1000px);
}

/* 모바일 - content-area 숨김 */
#content-area {
  display: none;
  overflow-anchor: none;
}

@media (min-width: 768px) {
  html,
  body {
    overflow: hidden;
    height: 100%;
  }
  #app {
    height: 100dvh;
    display: flex;
    flex-direction: column;
  }

  /* 데탑 헤더 */
  #guide-header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
  }

  #input-repo {
    max-width: 1200px;
  }

  .header-inputs {
    max-width: 900px;
    margin: 0 auto;

    grid-template-columns: 1fr 1fr 1fr 2.5fr;
    gap: 20px;
  }

  .header-inputs input {
    padding: 14px 20px;
    font-size: 15px;
    border-radius: 12px;
    transition: all 0.15s ease;
  }

  .header-inputs #input-repo {
    grid-column: auto;
  }

  #layout {
    display: flex;
    flex: 2;
    min-height: 0;
  }

  #content-area {
    flex: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: #020617;
    border-left: 1px solid #1e293b;
    min-height: 0;
  }

  .card {
    min-height: 50vh;
    padding: 29px 27px;
    display: flex;
    flex-direction: column;
    gap: 16px;
  }

  .card-title {
    white-space: pre-line;

    font-size: 1.5rem;
    font-weight: 700;
    color: #f1f5f9;
    margin-bottom: 10px;
  }

  .card-desc {
    font-size: 1rem;
    color: #94a3b8;
    line-height: 1.7;
  }
  .window-image {
    max-width: 800px;
    max-height: 600px;
    object-fit: contain;
    animation: bounceDown 1.2s infinite;
  }
  .card-intro {
    padding-top: 80px;
    padding-bottom: 180px;
  }
}

.active .card-text .card-title,
.active .card-text .card-intro-title {
  color: var(--color-woowahan);
}

@media (min-width: 1000px) {
  #layout {
    flex: 1;
  }

  #content-area {
    flex: 4;
  }
}

.card-intro {
  padding-top: 70px;
  padding-bottom: 180px;
}

.card-intro-title {
  font-size: 2.5rem;
  font-weight: 900;
  line-height: 1.2;
  color: white;
}

.card-intro-desc {
  font-size: 1rem;
  margin-top: 20px;
  color: #94a3b8;
}
.card-intro-helper {
  font-size: 0.8rem;
  color: #5b636f;
}

.card-intro-arrow {
  color: var(--color-woowahan);
  margin-top: 10px;
  display: inline-block;
  animation: bounceDown 1.2s infinite;
}

@keyframes bounceDown {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(6px);
  }
}

.window-body {
  flex: 1;
  padding: 12px;
}

.window-stage {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.visual-card {
  width: min(700px, 96%);
  min-height: 360px;
  padding: 48px 36px;
  border-radius: 32px;
  background-color: #1b1b20;
  border: 1px solid rgba(255, 255, 255, 0.04);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  text-align: center;
}

.visual-icon {
  font-size: 52px;
  line-height: 1;
}

.visual-label {
  margin: 0;
  color: #d1d5db;
  font-size: clamp(30px, 3.2vw, 46px);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.02em;
}

.visual-meta {
  white-space: pre-line;
  padding: 18px 22px;
  min-width: 68%;
  border-radius: 18px;
  color: #7f8db0;
  font-size: 18px;
  line-height: 1.65;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.visual-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 14px;
  background: rgb(0, 146, 27);
  color: #e5ebe5;
  text-decoration: none;
  font-weight: 700;
  transition:
    transform 0.2s ease,
    background 0.2s ease;
  animation: bounceDown 1.2s infinite;
}

.visual-btn:hover {
  background: var(--color-woowahan2);
  color: black;
  transform: translateY(-1px);
}

.window-image {
  object-fit: contain;
  animation: bounceDown 1.2s infinite;
}

.card-mobile-content {
  margin-top: 16px;
}

@media (min-width: 768px) {
  .card-mobile-content {
    display: none;
  }
}
.card-mobile-content {
  margin-top: 16px;
}

.card-mobile-content .mac-window {
  width: 100%;
}

.card-mobile-content .window-body {
  min-height: auto;
  padding: 12px;
}

.card-mobile-content .window-image {
  width: 100% !important;
  max-width: 100%;
  height: auto !important;
  max-height: none;
  object-fit: contain;
}

.card-mobile-content .visual-card {
  width: 100%;
  min-height: auto;
  padding: 28px 20px;
  border-radius: 20px;
}

.card-mobile-content .visual-label {
  font-size: 1.2rem;
}

.window-body {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  min-height: 300px;
  transition: all 2s ease;
}
