* {
  box-sizing: border-box;
}

body {
  font-family: Pretendard, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans KR", "Apple SD Gothic Neo", sans-serif;
}

.wrapper {
  overflow: visible;
}

.services-root {
  scroll-behavior: smooth;
  min-height: 100vh;
  background-color: #ffffff;
  color: #171717;
}

.services-container {
  margin-left: auto;
  margin-right: auto;
  max-width: 80rem;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
  margin-bottom: 10rem;
}

@media (min-width: 1024px) {
  .services-container {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }
}

.services-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 1024px) {
  .services-layout {
    grid-template-columns: repeat(12, 1fr);
  }
}

.services-content {
  grid-column: span 9;
}

@media (max-width: 1023px) {
  .services-content {
    grid-column: span 1;
  }
}

.services-sections {
  scroll-snap-type: y proximity;
}

/* =============================================================================
   HERO SECTION (SERVICES HERO)
   ============================================================================= */

.services-hero {
  padding-top: 4rem;
  padding-bottom: 4rem;
}

@media (min-width: 768px) {
  .services-hero {
    padding-top: 6rem;
    padding-bottom: 6rem;
  }
}

.services-hero__container {
  margin-left: auto;
  margin-right: auto;
  max-width: 80rem;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

@media (min-width: 1024px) {
  .services-hero__container {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}

.services-hero__header {
  text-align: center;
  max-width: 56rem;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 4rem;
}

.services-hero__header > * + * {
  margin-top: 1.5rem;
}

.services-hero__label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.services-hero__title {
  font-size: 1.875rem;
  font-weight: 700;
  color: #111827;
  line-height: 1.25;
}

@media (min-width: 768px) {
  .services-hero__title {
    font-size: 2.25rem;
  }
}

@media (min-width: 1024px) {
  .services-hero__title {
    font-size: 3rem;
  }
}

.services-hero__description {
  font-size: 1.125rem;
  color: #4b5563;
  line-height: 1.625;
}

.services-hero__description strong {
  color: var(--primary);
}
.services-hero__cta {
  display: flex;
  justify-content: center;
  margin-top: 3rem;
}

/* =============================================================================
   SIDEBAR NAVIGATION
   ============================================================================= */

.services-sidebar {
  display: none;
}

@media (min-width: 1024px) {
  .services-sidebar {
    display: block;
    grid-column: span 3;
  }
}

.services-nav {
  position: sticky;
  top: 7rem;
}

.services-nav__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.services-nav__list > * + * {
  margin-top: 0.5rem;
}

.services-nav__link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border-radius: 0.75rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all 0.3s ease;
  color: #525252;
  text-decoration: none;
}

.services-nav__link:hover {
  background-color: #fafafa;
}

.services-nav__link--active {
  background-color: rgba(37, 99, 235, 0.1);
  color: #1d4ed8;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.2);
}

.services-nav__dot {
  width: 0.625rem;
  height: 0.625rem;
  border-radius: 50%;
  background-color: #d4d4d4;
  flex-shrink: 0;
  transition: background-color 0.3s ease;
}

.services-nav__link:hover .services-nav__dot {
  background-color: #a3a3a3;
}

.services-nav__dot--active {
  background-color: #2563eb;
}

/* =============================================================================
   SERVICE SECTION
   ============================================================================= */

.service-section {
  scroll-snap-align: start;
  scroll-margin-top: 6rem;
  padding-top: 4rem;
  padding-bottom: 4rem;
  border-bottom: 1px solid #f5f5f5;
}

.service-section:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

@media (min-width: 768px) {
  .service-section {
    padding-top: 6rem;
    padding-bottom: 6rem;
  }
}

.service-section__grid {
  display: grid;
  align-items: center;
  gap: 2.5rem;
  grid-template-columns: 1fr;
}

@media (min-width: 1024px) {
  .service-section__grid {
    grid-template-columns: repeat(12, 1fr);
  }
}

.service-section__content {
  grid-column: span 6;
}

.service-section__content > * + * {
  margin-top: 1.25rem;
}

@media (min-width: 1024px) {
  .service-section__content > * + * {
    margin-top: 1.5rem;
  }
}

.service-section__content--reverse {
  grid-column: span 6;
  order: 2;
}

@media (min-width: 1024px) {
  .service-section__content--reverse {
    order: 2;
  }
}

.service-section__content--reverse > * + * {
  margin-top: 1.25rem;
}

@media (min-width: 1024px) {
  .service-section__content--reverse > * + * {
    margin-top: 1.5rem;
  }
}

.service-section__visual {
  grid-column: span 6;
}

.service-section__visual--reverse {
  grid-column: span 6;
  order: 1;
}

@media (min-width: 1024px) {
  .service-section__visual--reverse {
    order: 1;
  }
}

/* =============================================================================
   SERVICE SECTION CONTENT
   ============================================================================= */

.service-section__header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.service-section__badge {
  display: inline-flex;
  align-items: center;
  border-radius: 9999px;
  padding: 0.25rem 0.625rem;
  font-size: 0.75rem;
  font-weight: 600;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0);
}

.service-section__badge--blue {
  background-color: #0ea5e9;
  color: #ffffff;
}

.service-section__badge--green {
  background-color: #10b981;
  color: #ffffff;
}

.service-section__badge--indigo {
  background-color: #2563eb;
  color: #ffffff;
}

.service-section__badge--gray {
  background-color: #9ca3af;
  color: #ffffff;
}

.service-section__badge--slate {
  background-color: #334155;
  color: #ffffff;
}

.service-section__badge--zinc {
  background-color: #18181b;
  color: #ffffff;
}

.service-section__number {
  font-size: 0.75rem;
  color: #a3a3a3;
}

.service-section__title {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.375;
  color: #111827;
}

@media (min-width: 768px) {
  .service-section__title {
    font-size: 1.875rem;
  }
}

.service-section__description {
  color: #525252;
  line-height: 1.625;
}

/* =============================================================================
   SERVICE SECTION VISUAL CARD
   ============================================================================= */

.service-visual-card {
  position: relative;
  overflow: hidden;
  border-radius: 1.5rem;
  border: 1px solid #e5e5e5;
  background-color: #ffffff;
  padding: 1rem;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
}

@media (min-width: 768px) {
  .service-visual-card {
    padding: 1.5rem;
  }
}

.service-visual-card__content {
  aspect-ratio: 16/10;
  width: 100%;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
}

.service-visual-card__content--blue {
  background: linear-gradient(
    to bottom right,
    rgba(14, 165, 233, 0.2),
    rgba(59, 130, 246, 0.2)
  );
}

.service-visual-card__content--green {
  background: linear-gradient(
    to bottom right,
    rgba(16, 185, 129, 0.2),
    rgba(20, 184, 166, 0.2)
  );
}

.service-visual-card__content--indigo {
  background: linear-gradient(
    to bottom right,
    rgba(37, 99, 235, 0.2),
    rgba(37, 99, 235, 0.2)
  );
}

.service-visual-card__content--gray {
  background: linear-gradient(
    to bottom right,
    rgba(107, 114, 128, 0.2),
    rgba(107, 114, 128, 0.2)
  );
}

.service-visual-card__content--slate {
  background: linear-gradient(
    to bottom right,
    rgba(51, 65, 85, 0.2),
    rgba(100, 116, 139, 0.2)
  );
}

.service-visual-card__content--zinc {
  background: linear-gradient(
    to bottom right,
    rgba(24, 24, 27, 0.2),
    rgba(161, 161, 170, 0.2)
  );
}

.service-visual-card__image-container {
  position: relative;
  height: 100%;
  width: 100%;
}

.service-visual-card__image-frame {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  bottom: 0.75rem;
  left: 0.75rem;
  border-radius: 0.75rem;
  background-color: rgba(255, 255, 255, 0.65);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(8px);
}

.service-visual-card__image {
  border-radius: 0.75rem;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-visual-card__bg-blur-1 {
  pointer-events: none;
  position: absolute;
  right: -2rem;
  top: -2rem;
  height: 10rem;
  width: 10rem;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.4);
  filter: blur(32px);
}

.service-visual-card__bg-blur-2 {
  pointer-events: none;
  position: absolute;
  left: -2rem;
  bottom: -2.5rem;
  height: 10rem;
  width: 10rem;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.4);
  filter: blur(32px);
}

/* =============================================================================
   CTA SECTION
   ============================================================================= */

.services-cta {
  background: linear-gradient(to bottom right, #2563eb, #4338ca);
  padding-top: 5rem;
  padding-bottom: 5rem;
}

.services-cta__container {
  margin-left: auto;
  margin-right: auto;
  max-width: 72rem;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

@media (min-width: 1024px) {
  .services-cta__container {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}

.services-cta__wrapper {
  position: relative;
}

.services-cta__content {
  text-align: center;
}

.services-cta__content > * + * {
  margin-top: 3rem;
}

.services-cta__header > * + * {
  margin-top: 1.5rem;
}

.services-cta__title {
  font-size: 1.875rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.25;
}

@media (min-width: 768px) {
  .services-cta__title {
    font-size: 2.25rem;
  }
}

@media (min-width: 1024px) {
  .services-cta__title {
    font-size: 3rem;
  }
}

.services-cta__description {
  font-size: 1.125rem;
  color: #dbeafe;
  line-height: 1.625;
  max-width: 48rem;
  margin-left: auto;
  margin-right: auto;
}

@media (min-width: 768px) {
  .services-cta__description {
    font-size: 1.25rem;
  }
}

.services-cta__buttons {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  justify-content: center;
}

@media (min-width: 640px) {
  .services-cta__buttons {
    flex-direction: row;
  }
}

/* =============================================================================
   RESPONSIVE UTILITIES
   ============================================================================= */

/* Mobile-specific adjustments */
@media (max-width: 1023px) {
  .service-section__content--reverse {
    order: 1;
  }

  .service-section__visual--reverse {
    order: 2;
  }

  .service-section__content,
  .service-section__content--reverse,
  .service-section__visual,
  .service-section__visual--reverse {
    grid-column: span 1;
  }
}

/* =============================================================================
   ANIMATION SUPPORT
   ============================================================================= */

[data-aos] {
  pointer-events: none;
}

[data-aos].aos-animate {
  pointer-events: auto;
}

.transition-smooth {
  transition: all 0.3s ease-in-out;
}

/* =============================================================================
   ACCESSIBILITY
   ============================================================================= */

.focus-visible:focus {
  outline: none;
  box-shadow: 0 0 0 2px #3b82f6;
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .services-root {
    scroll-behavior: auto;
  }
}

/* =============================================================================
   PRINT STYLES
   ============================================================================= */

@media print {
  .services-cta {
    background: #2563eb !important;
    color: white !important;
  }

  .service-visual-card {
    box-shadow: none !important;
    border: 1px solid #e5e5e5 !important;
  }
}

/* =============================================================================
   BROWSER COMPATIBILITY
   ============================================================================= */

@supports not (display: grid) {
  .services-layout,
  .service-section__grid {
    display: flex;
    flex-wrap: wrap;
  }

  .services-content {
    flex: 1;
  }

  .services-sidebar {
    flex: 0 0 25%;
  }
}

@supports not (backdrop-filter: blur(8px)) {
  .service-visual-card__image-frame {
    background-color: rgba(255, 255, 255, 0.9);
  }
}
