/*
[생성일] 2026-08-02
[경위] 리본페인트 웹 제안서 — web-proposal-kit 템플릿(style.css)을 시안 팔레트(블랙·화이트·베이지)로 맞춤
[변경이력]
  - 2026-08-02: 최초 생성 (팔레트 교체, Noto Serif KR 추가, 시안 미리보기 카드·링크 버튼 스타일 추가)
*/

:root {
  /* 리본페인트 시안 팔레트 (04_design\2026-08-01_홈시안_v1.html 기준) */
  --color-bg-primary: #ffffff;
  --color-bg-secondary: #faf8f3; /* paper */
  --color-bg-tertiary: #eae3d6;  /* plaster */
  --color-text-primary: #1a1713; /* ink */
  --color-text-secondary: #3a342b;
  --color-text-tertiary: #5c5347; /* ink-soft */
  --color-point: #cdbfa8;        /* sand */
  --color-dark: #1a1713;

  --font-en: 'Outfit', sans-serif;
  --font-kr: 'Noto Sans KR', sans-serif;
  --font-serif: 'Noto Serif KR', serif; /* 시안과 같은 세리프 강조용 */
}

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

/* Lenis Recommended CSS */
html.lenis, html.lenis body {
  height: auto;
}
.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}
.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}
.lenis.lenis-stopped {
  overflow: hidden;
}
.lenis.lenis-scrolling iframe {
  pointer-events: none;
}

body {
  font-family: var(--font-kr);
  color: var(--color-text-primary);
  background-color: var(--color-bg-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  word-break: keep-all; /* 한글 단어가 중간에서 끊기지 않게 */
  overflow-wrap: break-word;
}

/* Typography Base */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-en);
  font-weight: 300;
  letter-spacing: -0.02em;
}

/* 시안 톤의 한글 세리프 강조 */
.serif-kr {
  font-family: var(--font-serif);
  font-weight: 300;
  letter-spacing: 0.02em;
}

.v2-container {
  width: 100%;
  overflow-x: clip;
}

/* Sections */
.section {
  position: relative;
  width: 100%;
  min-height: 100vh;
  padding: 120px 8vw;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.section.full-height {
  height: 100vh;
}

.section.dark {
  background-color: var(--color-dark);
  color: var(--color-bg-secondary);
}

.section.bg-secondary {
  background-color: var(--color-bg-secondary);
}

.section.bg-tertiary {
  background-color: var(--color-bg-tertiary);
}

/* Typography styles */
.text-giant {
  font-size: clamp(4rem, 8vw, 10rem);
  font-weight: 100;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: -0.04em;
}
.text-giant strong {
  font-weight: 600;
  color: var(--color-point);
}

.text-title {
  font-size: clamp(2rem, 4vw, 4rem);
  font-weight: 500;
  margin-bottom: 24px;
}

.text-desc {
  font-size: clamp(1rem, 1.2vw, 1.5rem);
  color: var(--color-text-secondary);
  font-weight: 400;
  line-height: 1.8;
  max-width: 650px;
}
.section.dark .text-desc {
  color: #b7ad9d;
}

/* Utility */
.flex-split {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  gap: 80px;
}
@media (max-width: 1024px) {
  .flex-split {
    flex-direction: column;
  }
}

.image-container {
  position: relative;
  overflow: hidden;
  border-radius: 4px;
  background-color: var(--color-bg-tertiary);
}
.image-container img,
.image-container video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1s cubic-bezier(0.165, 0.84, 0.44, 1);
}
.image-container:hover img,
.image-container:hover video {
  transform: scale(1.05);
}
.no-zoom:hover img,
.no-zoom:hover video {
  transform: scale(1) !important;
}

/* 시안 미리보기 카드 (PC·태블릿·모바일 스크린샷) */
.preview-card {
  flex: 1;
  min-width: 0;
  background-color: var(--color-bg-primary);
  border: 1px solid #ddd5c4;
  box-shadow: 0 20px 60px rgba(26, 23, 19, 0.06);
}
.preview-card .device-label {
  display: block;
  padding: 18px 24px;
  font-family: var(--font-en);
  font-size: 0.85rem;
  letter-spacing: 2px;
  color: var(--color-text-tertiary);
  border-bottom: 1px solid #eee7d9;
}
.preview-crop {
  height: 620px;
  overflow: hidden;
  background-color: var(--color-bg-secondary);
}
.preview-crop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top; /* 긴 스크린샷의 첫 화면 부분만 보여줌 */
}
@media (max-width: 768px) {
  .preview-crop {
    height: 420px;
  }
}

/* 시안 바로가기 링크 버튼 */
.link-btn {
  display: inline-block;
  padding: 16px 36px;
  border: 1px solid var(--color-point);
  font-family: var(--font-en);
  font-size: 0.95rem;
  letter-spacing: 1.5px;
  text-decoration: none;
  color: var(--color-text-primary);
  transition: background-color 0.3s ease, color 0.3s ease;
}
.section.dark .link-btn {
  color: var(--color-bg-secondary);
}
.link-btn:hover,
.link-btn:focus-visible {
  background-color: var(--color-point);
  color: var(--color-dark);
}
.link-btn:focus-visible {
  outline: 2px solid var(--color-point);
  outline-offset: 3px;
}

/* Overlapping effects */
.overlap-box {
  position: relative;
  z-index: 2;
  margin-top: -100px;
  margin-left: auto;
  background: var(--color-bg-primary);
  padding: 60px;
  width: 80%;
  box-shadow: 0 40px 100px rgba(0,0,0,0.03);
}

/* Big number */
.big-number {
  font-family: var(--font-en);
  font-size: 20vw;
  font-weight: 200;
  color: rgba(26, 23, 19, 0.04);
  position: absolute;
  top: 0;
  right: 8vw;
  z-index: 0;
  line-height: 0.8;
  pointer-events: none;
}
.section.dark .big-number {
  color: rgba(250, 248, 243, 0.04);
}

/* Ensure content stays above the big number */
.section > *:not(.big-number) {
  position: relative;
  z-index: 10;
}

/* Decor line */
.decor-line {
  width: 60px;
  height: 1px;
  background-color: var(--color-point);
  margin: 40px 0;
}

/* GSAP Default Hidden Class */
.gsap-fade-up, .gsap-fade-in, .gsap-slide-left, .gsap-slide-right {
  /* JS가 에러나도 내용이 보이도록 CSS에서 강제로 숨기지 않음 */
}

/* Carousel */
.carousel-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}
.carousel-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  z-index: 0;
  transition: opacity 1.5s ease-in-out, transform 6s ease-out;
  transform: scale(1.05);
}
.carousel-img.prev-active {
  opacity: 1;
  z-index: 1;
  transform: scale(1);
  transition: opacity 0s, transform 6s ease-out;
}
.carousel-img.active {
  opacity: 1;
  z-index: 2;
  transform: scale(1);
  transition: opacity 1.5s ease-in-out, transform 6s ease-out;
}
.carousel-indicators {
  position: absolute;
  bottom: 5%;
  right: 5%;
  display: flex;
  gap: 10px;
  z-index: 10;
}
.carousel-dot {
  width: 40px;
  height: 2px;
  background-color: rgba(255,255,255,0.3);
  transition: background-color 0.5s;
}
.carousel-dot.active {
  background-color: var(--color-bg-primary);
}

/* -------------------------------------
   Mobile & Tablet Responsive
-------------------------------------- */
@media (max-width: 1024px) {
  .section {
    padding: 100px 5vw !important;
  }
  /* Split Layouts to Column */
  .flex-split {
    flex-direction: column !important;
    gap: 40px !important;
    height: auto !important;
  }
  .flex-split > div {
    width: 100% !important;
  }
  /* Slide 1 specific */
  .section.full-height .flex-split > div:first-child {
    padding: 60px 5vw !important;
  }
  .section.full-height .flex-split > div:last-child {
    height: 60vh !important;
    min-height: 400px;
  }
  .section.full-height .flex-split > div:last-child > .gsap-fade-up {
    left: 5% !important;
    bottom: 5% !important;
    padding: 20px !important;
    width: 90% !important;
  }
  /* Typography Adjustments */
  .text-giant {
    font-size: clamp(3rem, 12vw, 5rem) !important;
  }
  .text-title {
    font-size: clamp(1.8rem, 8vw, 2.5rem) !important;
  }
  /* Boxes and Containers */
  div[style*="display: flex; gap: 40px;"] {
    flex-direction: column !important;
    padding: 30px !important;
    gap: 20px !important;
  }
  div[style*="padding: 50px; display: flex"] {
    flex-direction: column !important;
    padding: 30px !important;
    gap: 15px !important;
  }
  /* Slide 11 미리보기 카드 세로 전환 */
  #slide11 > div:last-child {
    flex-direction: column !important;
    height: auto !important;
    gap: 20px !important;
  }
  /* Slide 13 & 15 Tables / Lists */
  div[style*="padding: 30px 0"], div[style*="padding: 40px 0"] {
    flex-direction: column !important;
    align-items: flex-start !important;
    padding: 20px 0 !important;
  }
  div[style*="padding: 30px 0"] > div, div[style*="padding: 40px 0"] > div {
    width: 100% !important;
    text-align: left !important;
    margin-bottom: 5px;
  }
  div[style*="padding: 30px 0"] > div.mobile-right {
    text-align: right !important;
    padding-right: 0 !important;
  }
  /* Slide 8 시공 분야 5종 박스 */
  div[style*="display: flex"][style*="gap: 2px"] {
    flex-wrap: wrap !important;
  }
  div[style*="display: flex"][style*="gap: 2px"] > div {
    width: 49% !important;
    padding: 20px 0 !important;
    flex: auto !important;
  }
  /* Slide 12 Estimate Header */
  .estimate-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 30px !important;
  }
  .estimate-header > div {
    text-align: left !important;
  }
}

@media (max-width: 768px) {
  .pc-only { display: none !important; }
  .section {
    padding: 80px 5vw !important;
    min-height: auto !important;
  }
  .section.full-height {
    height: auto !important;
  }
  /* Big Number */
  .big-number {
    font-size: 40vw;
    top: 50px;
    right: 5vw;
    opacity: 0.5;
  }
  .decor-line {
    margin: 20px 0;
  }
  /* Hide slide 1 indicators on mobile to save space */
  .carousel-indicators {
    bottom: 2%;
    transform: scale(0.8);
  }
}

/* 접근성: 움직임 최소화 설정 시 전환 효과 제거 */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* Top Button */
.top-btn {
  position: fixed;
  bottom: 40px;
  right: 40px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: var(--color-dark);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 100;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, background-color 0.3s ease;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.top-btn.show {
  opacity: 1;
  visibility: visible;
}
.top-btn:hover {
  background-color: var(--color-point);
  color: var(--color-dark);
  transform: translateY(-3px);
}
@media (max-width: 768px) {
  .top-btn {
    bottom: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
  }
}
