/* ==========================================================
   THE WITHIN — Company Website Stylesheet
   ========================================================== */

:root {
  --primary: #1d5bff;
  --primary-dark: #0f3fd4;
  --primary-light: #e8efff;
  --navy: #0b1b3f;
  --navy-soft: #16295c;
  --teal: #00b8a9;
  --amber: #ff9f43;
  --text: #23293a;
  --text-sub: #5b6478;
  --line: #e4e8f0;
  --bg-soft: #f5f7fb;
  --white: #ffffff;
  --radius: 16px;
  --shadow: 0 8px 30px rgba(11, 27, 63, 0.08);
  --shadow-hover: 0 14px 40px rgba(11, 27, 63, 0.14);
  --maxw: 1140px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont,
    "Apple SD Gothic Neo", "Malgun Gothic", "Segoe UI", sans-serif;
  color: var(--text);
  line-height: 1.65;
  background: var(--white);
  word-break: keep-all;
}

img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; }

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* ----------------------------------------------------------
   Header
   ---------------------------------------------------------- */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 20px;
  letter-spacing: 0.02em;
  color: var(--navy);
}

.logo img {
  height: 46px;
  width: auto;
}

.logo__mark {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--teal) 100%);
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 15px;
  font-weight: 900;
}

.logo strong { color: var(--primary); }

.gnb { display: flex; align-items: center; gap: 34px; }

.gnb a {
  position: relative;
  padding: 8px 2px;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: #7a8296;
  transition: color 0.3s ease;
}

.gnb a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 2px;
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--navy) 60%, #b3413a);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.3s ease;
}

.gnb a:hover { color: var(--navy); }
.gnb a:hover::after { transform: scaleX(1); }

.gnb a.is-active { color: var(--navy); font-weight: 700; }
.gnb a.is-active::after {
  transform: scaleX(1);
  background: #b3413a;
}

.gnb a.gnb__cta {
  margin-left: 8px;
  padding: 12px 28px;
  font-size: 16px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--navy-soft) 0%, var(--navy) 100%);
  color: #fff;
  letter-spacing: 0.03em;
  box-shadow: 0 4px 14px rgba(11, 27, 63, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.gnb a.gnb__cta::after { display: none; }
.gnb a.gnb__cta:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(11, 27, 63, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  width: 44px;
  height: 44px;
  position: relative;
}
.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  position: absolute;
  left: 10px;
  width: 24px;
  height: 2.5px;
  border-radius: 2px;
  background: var(--navy);
  transition: transform 0.25s, opacity 0.2s;
}
.nav-toggle span { top: 21px; }
.nav-toggle span::before { top: -8px; left: 0; }
.nav-toggle span::after { top: 8px; left: 0; }

.nav-open .nav-toggle span { background: transparent; }
.nav-open .nav-toggle span::before { transform: translateY(8px) rotate(45deg); }
.nav-open .nav-toggle span::after { transform: translateY(-8px) rotate(-45deg); }

/* ----------------------------------------------------------
   Hero (main)
   ---------------------------------------------------------- */
.hero {
  background:
    radial-gradient(900px 400px at 85% -10%, rgba(0, 184, 169, 0.18), transparent 60%),
    radial-gradient(800px 500px at 10% 110%, rgba(29, 91, 255, 0.16), transparent 55%),
    var(--navy);
  color: #fff;
  padding: 96px 0 110px;
  overflow: hidden;
}

.hero__eyebrow {
  display: inline-block;
  padding: 7px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 22px;
}

.hero h1 {
  font-size: clamp(30px, 4.6vw, 48px);
  line-height: 1.32;
  font-weight: 800;
  margin-bottom: 20px;
}

.hero h1 em {
  font-style: normal;
  background: linear-gradient(90deg, #6ea8ff, #4de3d4);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero p {
  font-size: clamp(16px, 2vw, 19px);
  color: rgba(255, 255, 255, 0.82);
  max-width: 640px;
  margin-bottom: 36px;
}

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

/* ----------------------------------------------------------
   Buttons
   ---------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 700;
  border: none;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}
.btn:hover { transform: translateY(-2px); }

.btn--primary { background: var(--primary); color: #fff; box-shadow: 0 6px 20px rgba(29, 91, 255, 0.35); }
.btn--primary:hover { background: var(--primary-dark); }

.btn--ghost {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.35);
}
.btn--ghost:hover { background: rgba(255, 255, 255, 0.18); }

.btn--outline {
  background: #fff;
  color: var(--primary);
  border: 1.5px solid var(--primary);
}
.btn--outline:hover { background: var(--primary-light); }

/* ----------------------------------------------------------
   Sections
   ---------------------------------------------------------- */
.section { padding: 90px 0; }
.section--soft { background: var(--bg-soft); }
.section--navy { background: var(--navy); color: #fff; }

.section__head { text-align: center; max-width: 720px; margin: 0 auto 56px; }

.section__eyebrow {
  display: inline-block;
  color: var(--primary);
  font-weight: 800;
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.section--navy .section__eyebrow { color: #6ea8ff; }

.section__title {
  font-size: clamp(24px, 3.4vw, 36px);
  font-weight: 800;
  line-height: 1.35;
  margin-bottom: 14px;
  color: var(--navy);
}
.section--navy .section__title { color: #fff; }

.section__desc { color: var(--text-sub); font-size: 17px; }
.section--navy .section__desc { color: rgba(255, 255, 255, 0.75); }

/* ----------------------------------------------------------
   Easy intro strip ("쉽게 말하면")
   ---------------------------------------------------------- */
.easy-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.easy-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 34px 28px;
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
}
.easy-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-hover); }

.easy-card__icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  margin-bottom: 20px;
  font-size: 26px;
}
.easy-card__icon--blue { background: var(--primary-light); }
.easy-card__icon--teal { background: #e0f7f5; }
.easy-card__icon--amber { background: #fff2e2; }

.easy-card h3 { font-size: 20px; font-weight: 800; color: var(--navy); margin-bottom: 6px; }

.easy-card .easy-card__tag {
  font-size: 13px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 12px;
}

.easy-card p { color: var(--text-sub); font-size: 15.5px; flex: 1; }

.easy-card__example {
  margin-top: 18px;
  padding: 14px 16px;
  background: var(--bg-soft);
  border-radius: 10px;
  font-size: 14px;
  color: var(--text);
}
.easy-card__example strong { color: var(--primary-dark); }

.easy-card__link {
  margin-top: 20px;
  color: var(--primary);
  font-weight: 700;
  font-size: 15px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.easy-card__link:hover { text-decoration: underline; }

/* ----------------------------------------------------------
   Feature rows (main page: 왜 THE WITHIN인가)
   ---------------------------------------------------------- */
.why-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.why-item {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  padding: 28px 24px;
}

.why-item__num { font-size: 14px; font-weight: 800; color: #4de3d4; margin-bottom: 10px; }
.why-item h3 { font-size: 18px; margin-bottom: 8px; }
.why-item p { font-size: 14.5px; color: rgba(255, 255, 255, 0.72); }

/* ----------------------------------------------------------
   Steps (도입 절차 / 작동 방식)
   ---------------------------------------------------------- */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  counter-reset: step;
}

.steps--3 { grid-template-columns: repeat(3, 1fr); }

.step {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 24px 26px;
  box-shadow: var(--shadow);
}

.step__badge {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-weight: 800;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
  font-size: 16px;
}

.step h3 { font-size: 17px; font-weight: 800; color: var(--navy); margin-bottom: 8px; }
.step p { font-size: 14.5px; color: var(--text-sub); }

/* ----------------------------------------------------------
   Service page: hero
   ---------------------------------------------------------- */
.svc-hero {
  padding: 80px 0 70px;
  color: #fff;
}
.svc-hero--cms { background: linear-gradient(120deg, #0f3fd4 0%, #1d5bff 55%, #3f7dff 100%); }
.svc-hero--va { background: linear-gradient(120deg, #00695f 0%, #00b8a9 60%, #2ed6c8 100%); }
.svc-hero--ob { background: linear-gradient(120deg, #b35a00 0%, #ff9f43 65%, #ffc07a 100%); }

.svc-hero__label {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  font-size: 13.5px;
  font-weight: 700;
  margin-bottom: 18px;
}

.svc-hero h1 { font-size: clamp(28px, 4vw, 42px); font-weight: 800; margin-bottom: 14px; line-height: 1.3; }
.svc-hero p { font-size: clamp(16px, 2vw, 19px); max-width: 680px; opacity: 0.92; }

/* ----------------------------------------------------------
   Service page: "이게 뭔가요" analogy box
   ---------------------------------------------------------- */
.what-box {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}

.what-box__text h2 { font-size: clamp(22px, 3vw, 30px); color: var(--navy); font-weight: 800; margin-bottom: 18px; line-height: 1.4; }
.what-box__text p { color: var(--text-sub); font-size: 16.5px; margin-bottom: 14px; }
.what-box__text p strong { color: var(--text); }

.analogy {
  background: #fff;
  border: 2px dashed var(--primary);
  border-radius: var(--radius);
  padding: 30px 28px;
}
.analogy__title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  color: var(--primary-dark);
  font-size: 16px;
  margin-bottom: 12px;
}
.analogy p { font-size: 15.5px; color: var(--text); }
.analogy p + p { margin-top: 10px; }

/* ----------------------------------------------------------
   Use-case cards
   ---------------------------------------------------------- */
.usecase-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.usecase {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 24px 20px;
  text-align: center;
  box-shadow: var(--shadow);
}
.usecase__emoji { font-size: 34px; margin-bottom: 12px; }
.usecase h3 { font-size: 16px; font-weight: 800; color: var(--navy); margin-bottom: 6px; }
.usecase p { font-size: 13.5px; color: var(--text-sub); }

/* ----------------------------------------------------------
   Flow diagram
   ---------------------------------------------------------- */
.flow {
  display: flex;
  align-items: stretch;
  gap: 0;
  flex-wrap: wrap;
  justify-content: center;
}

.flow__node {
  flex: 1;
  min-width: 190px;
  max-width: 250px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 26px 20px;
  text-align: center;
  box-shadow: var(--shadow);
  position: relative;
}

.flow__node--accent { border-color: var(--primary); border-width: 2px; }

.flow__icon { font-size: 30px; margin-bottom: 10px; }
.flow__node h3 { font-size: 15.5px; font-weight: 800; color: var(--navy); margin-bottom: 6px; }
.flow__node p { font-size: 13.5px; color: var(--text-sub); }

.flow__arrow {
  display: grid;
  place-items: center;
  padding: 0 14px;
  color: var(--primary);
  font-size: 22px;
  font-weight: 800;
}

/* ----------------------------------------------------------
   Benefit list
   ---------------------------------------------------------- */
.benefit-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.benefit {
  display: flex;
  gap: 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 26px;
  box-shadow: var(--shadow);
}

.benefit__icon {
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--primary-light);
  display: grid;
  place-items: center;
  font-size: 22px;
}

.benefit h3 { font-size: 17px; font-weight: 800; color: var(--navy); margin-bottom: 6px; }
.benefit p { font-size: 14.5px; color: var(--text-sub); }

/* ----------------------------------------------------------
   FAQ accordion
   ---------------------------------------------------------- */
.faq { max-width: 800px; margin: 0 auto; }

.faq__item {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  margin-bottom: 12px;
  overflow: hidden;
}

.faq__q {
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  padding: 20px 24px;
  font-size: 16px;
  font-weight: 700;
  color: var(--navy);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.faq__q::after {
  content: "+";
  font-size: 22px;
  color: var(--primary);
  transition: transform 0.25s;
  flex: none;
}

.faq__item.is-open .faq__q::after { transform: rotate(45deg); }

.faq__a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq__a-inner {
  padding: 0 24px 22px;
  color: var(--text-sub);
  font-size: 15px;
}

/* ----------------------------------------------------------
   CTA band
   ---------------------------------------------------------- */
.cta-band {
  background:
    radial-gradient(700px 300px at 90% 0%, rgba(0, 184, 169, 0.25), transparent 60%),
    var(--navy);
  color: #fff;
  text-align: center;
  padding: 80px 24px;
}

.cta-band h2 { font-size: clamp(24px, 3.4vw, 34px); font-weight: 800; margin-bottom: 14px; }
.cta-band p { color: rgba(255, 255, 255, 0.78); margin-bottom: 32px; font-size: 17px; }

/* ----------------------------------------------------------
   Contact
   ---------------------------------------------------------- */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.contact-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px 26px;
  text-align: center;
  box-shadow: var(--shadow);
}

.contact-card__icon { font-size: 32px; margin-bottom: 14px; }
.contact-card h3 { font-size: 17px; font-weight: 800; color: var(--navy); margin-bottom: 8px; }
.contact-card p { font-size: 15px; color: var(--text-sub); }
.contact-card a { color: var(--primary); font-weight: 700; }
.contact-card a:hover { text-decoration: underline; }

/* ----------------------------------------------------------
   Company page
   ---------------------------------------------------------- */
.about-values {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.value-card {
  background: #fff;
  border-top: 4px solid var(--primary);
  border-radius: 14px;
  padding: 30px 26px;
  box-shadow: var(--shadow);
}
.value-card:nth-child(2) { border-top-color: var(--teal); }
.value-card:nth-child(3) { border-top-color: var(--amber); }

.value-card h3 { font-size: 18px; font-weight: 800; color: var(--navy); margin-bottom: 10px; }
.value-card p { font-size: 14.5px; color: var(--text-sub); }

.info-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.info-table th,
.info-table td {
  padding: 18px 24px;
  text-align: left;
  font-size: 15px;
  border-bottom: 1px solid var(--line);
}
.info-table tr:last-child th,
.info-table tr:last-child td { border-bottom: none; }
.info-table th { width: 180px; background: var(--bg-soft); color: var(--navy); font-weight: 700; }
.info-table td { color: var(--text-sub); }

/* ----------------------------------------------------------
   Footer
   ---------------------------------------------------------- */
.footer {
  background: #0a1430;
  color: rgba(255, 255, 255, 0.6);
  padding: 56px 0 40px;
  font-size: 14px;
}

.footer__top {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 28px;
}

.footer .logo { color: #fff; margin-bottom: 16px; }
.footer .logo img { height: 54px; }

.footer__nav { display: flex; gap: 28px; flex-wrap: wrap; }
.footer__nav a { color: rgba(255, 255, 255, 0.75); font-weight: 600; }
.footer__nav a:hover { color: #fff; }

.footer__info p { margin-bottom: 6px; }
.footer__copy { margin-top: 20px; font-size: 13px; color: rgba(255, 255, 255, 0.4); }

/* ----------------------------------------------------------
   Reveal animation
   ---------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* ----------------------------------------------------------
   Responsive
   ---------------------------------------------------------- */
@media (max-width: 960px) {
  .easy-grid,
  .about-values,
  .contact-grid { grid-template-columns: 1fr; }

  .why-grid,
  .steps,
  .usecase-grid,
  .benefit-grid { grid-template-columns: repeat(2, 1fr); }

  .steps--3 { grid-template-columns: 1fr; }

  .what-box { grid-template-columns: 1fr; gap: 32px; }

  .flow { flex-direction: column; align-items: center; }
  .flow__node { max-width: 420px; width: 100%; }
  .flow__arrow { transform: rotate(90deg); padding: 10px 0; }
}

@media (max-width: 720px) {
  .section { padding: 64px 0; }
  .hero { padding: 72px 0 84px; }

  .why-grid,
  .steps,
  .usecase-grid,
  .benefit-grid { grid-template-columns: 1fr; }

  .nav-toggle { display: block; }

  .gnb {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: #fff;
    flex-direction: column;
    align-items: stretch;
    padding: 12px 20px 20px;
    gap: 4px;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    display: none;
  }

  .nav-open .gnb { display: flex; }

  .gnb { gap: 4px; }
  .gnb a { padding: 13px 16px; border-radius: 10px; }
  .gnb a::after { display: none; }
  .gnb a:hover { background: var(--bg-soft); }
  .gnb a.gnb__cta { margin-left: 0; margin-top: 8px; text-align: center; }

  .info-table th { width: 110px; }
}
