:root {
  --font-size-base: 16px;
  --font-size-lg: 2.5rem;
  --font-size-md: 2rem;
  --font-size-sm: 1rem;
}

body {
  font-size: var(--font-size-base);
}

h1 {
  font-size: var(--font-size-lg);
}

h2 {
  font-size: var(--font-size-md);
}

p {
  font-size: var(--font-size-sm);
}

.subtitle {
  color: #666;
  font-size: 18px;
}

.description {
  font-size: 14px;
  padding: 10px;
  line-height: 1.6;
  color: #333;
}

@media (max-width: 768px) {
  :root {
      --font-size-base: 14px;
      --font-size-lg: 2rem;
      --font-size-md: 1.5rem;
      --font-size-sm: 0.875rem;
  }
}

@media (max-width: 576px) {
  :root {
      --font-size-base: 12px;
      --font-size-lg: 1.5rem;
      --font-size-md: 1.25rem;
      --font-size-sm: 0.75rem;
  }
}

.container-fluid {
  padding: 20px;
}

.navbar-brand img {
  width: 100%;
  max-width: 150px;
}

.swiper {
  width: 100%;
}

.swiper-slide {
  flex: 0 0 auto;
}

@media (max-width: 768px) {
  .display-1 {
      font-size: 3rem;
  }

  .swiper-slide {
      width: 100%;
  }
}

@media (max-width: 576px) {
  .display-1 {
      font-size: 2.5rem;
  }

  .navbar-nav {
      flex-direction: column;
  }

  .navbar-nav .nav-item {
      margin-bottom: 10px;
  }

  .card-body p {
      font-size: 0.875rem;
  }
}

/* *Youtube css */
.video-container {
  position: relative;
  width: 100%;
  max-width: 800px;
  margin: auto;
}

.video-container img {
  width: 100%;
  height: auto;
  display: block;
}

.video-container .youtube-video {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 70%;
  height: 70%;
}

.divider {
  width: 980px;
  border-bottom: 2px solid #6F6DA3;
  margin-bottom: 20px;
}

.email-link .email-icon {
  transition: transform 0.2s, background-image 0.2s;
}

.email-link:hover .email-icon {
  content: url("/assets/images/email_hover.png");
}

.recruit-link .recruit-icon {
  transition: transform 0.2s, background-image 0.2s;
}

.recruit-link:hover .recruit-icon {
  content: url("/assets/images/recruit_pencil_hover.png");
}


/* About Section and Recruit Section Responsive Styling */

#about-section .col,
#recruit-section .col {
  max-width: 100%;
  margin-bottom: 20px;
  /* Adds space between items in mobile view */
}

/* 모바일 화면에서 연도와 설명이 더 많은 가로 공간을 차지하도록 설정 */
@media (max-width: 768px) {
  #history-section {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  #history-section .container {
    padding-left: 10px;
    padding-right: 10px;
  }
  #history-section .col-md-2.d-none.d-md-block {
    display: none;
  }
  #history-section .col-md-10.col-xl-8.col-12 {
    padding-left: 0;
    padding-right: 0;
    width: 100%;
  }
  .step {
    display: flex;
    align-items: flex-start;
    width: 100%;
    margin: 0;
  }
  .step .fs-6.fw-bold {
    width: auto;
    flex: 0 0 25%; /* 연도 부분을 약 15%로 설정 */
    padding-left: 20px; /* 연도 부분 좌측 여백 추가 */
    font-size: 2rem; /* 연도 글자 크기 줄임 */
  }
  .step-body {
    flex: 1;
    max-width: 80%; /* 나머지 공간을 설명 부분이 차지 */
  }
  .step-body p {
    margin-left: 0;
    text-align: left;
    word-wrap: break-word; /* 단어가 길 경우 자동 줄바꿈 */
    padding-right: 20px;
  }

  h2.text-start {
    text-align: center;
    width: 100%;
  }
}

/* 모바일 화면에서 양옆의 여백 없애기 */
@media (max-width: 768px) {
  #organization-section, #business-section {
    padding-left: 0 !important;
    padding-right: 0 !important;
    padding-bottom: 50px;
  }
  #organization-section .container, #business-section .container {
    padding-left: 10px; /* 컨테이너 좌우 여백 추가 */
    padding-right: 10px; /* 컨테이너 좌우 여백 추가 */
  }
  #organization-section .col-md-12, #organization-section .col-xl-12, #business-section .col-lg-12, #business-section .col-xl-12, #business-section .col-xxl-12 {
    padding-left: 0;
    padding-right: 0;
  }
  #organization-section .d-flex, #business-section .row-cols-1 {
    padding-left: 10px;
    padding-right: 10px;
  }
}

/* 모바일 화면에서 양옆의 여백 없애기 */
@media (max-width: 768px) {
  #visit-section {
    padding-left: 0 !important;
    padding-right: 0 !important;
    padding-bottom: 50px;
  }
  #visit-section .container {
    padding-left: 10px; /* 컨테이너 좌우 여백 추가 */
    padding-right: 10px; /* 컨테이너 좌우 여백 추가 */
  }
  #visit-section .d-flex {
    padding-left: 10px;
    padding-right: 10px;
  }
}

/* 모바일 화면에서 양옆의 여백 없애기 */
@media (max-width: 768px) {
  #partner-section {
    padding-left: 0 !important;
    padding-right: 0 !important;
    padding-bottom: 50px;
  }
  #partner-section .container {
    padding-left: 10px; /* 컨테이너 좌우 여백 추가 */
    padding-right: 10px; /* 컨테이너 좌우 여백 추가 */
  }
  #partner-section .d-flex {
    padding-left: 10px;
    padding-right: 10px;
  }

  #partner-section .divider {
    width: 350px;
    border-bottom: 2px solid #6F6DA3;
    margin-bottom: 20px;
  }
}


/* 모바일 화면에서 요구 사항 섹션 스타일 조정 */
@media (max-width: 768px) {
  .bg-skill, .bg-experience {
    font-size: 1rem; /* 배경 색상 텍스트 크기 조정 */
  }
  .custom-skill-border, .custom-experience-border {
    font-size: 0.8rem; /* 리스트 항목 텍스트 크기 조정 */
    padding: 0.5rem; /* 패딩 조정 */
  }
  .custom-rounded-top-left, .custom-rounded-top-right,
  .custom-rounded-bottom-left, .custom-rounded-bottom-right {
    font-size: 0.8rem; /* 타이틀 텍스트 크기 조정 */
  }
  .custom-skill-border ul, .custom-experience-border ul {
    padding-left: 1rem; /* 리스트 여백 조정 */
  }
  .custom-skill-border ul li, .custom-experience-border ul li {
    margin-bottom: 0.5rem; /* 리스트 항목 간격 조정 */
  }
}

/* 모바일 화면에서 채용 절차 섹션 스타일 조정 */
@media (max-width: 768px) {
  #procedure-section .container {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  #procedure-section .col-12 {
    padding-left: 0;
    padding-right: 0;
  }

  #procedure-section .ps-md-4, #procedure-section .ps-lg-0 {
    padding-left: 0 !important;
  }

  #procedure-section .custom-card {
    width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  #procedure-section .custom-card .card {
    width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  #procedure-section .custom-card .card-body {
    padding-left: 3rem !important;
    padding-right: 1rem !important;
    position: relative;
  }

  #procedure-section .custom-card .card-text {
    width: calc(100%) !important; /* 이미지 공간을 제외한 너비 */
    margin-right: 0px; /* 이미지 공간 확보 */
  }
  
  #procedure-section img.recruit-icon {
    width: 40px;
    height: 40px;
    position: absolute;
    right: 0px;
    top: 50%;
    transform: translateY(-50%);
  }
}

@media (max-width: 768px) {
  .custom-border-top,
  .custom-border-middle {
    width: 100%;
    margin: 0;
  }

  .col-md-3 {
    width: 100%;
  }

  .circle-border {
    width: 50px;
    height: 50px;
  }

  svg.bi-check2,
  svg.bi-chevron-double-down {
    width: 24px;
    height: 24px;
  }

  p.h5, p.h6 {
    font-size: 14px;
  }

  h4 {
    font-size: 16px;
  }

  .row {
    margin: 0;
  }
}