/* ==========================================================================
   Responsive — SBS 아카데미 뷰티스타일
   반응형 미디어쿼리
   - Wide:    1280px+   (기본 — sections.css에 정의)
   - Desktop: 1024-1279px
   - Tablet:  768-1023px
   - Mobile:  ≤767px
   ========================================================================== */

/* ── Desktop (1024-1279px) ── */
@media (max-width: 1279px) {
  .hero__content { padding: 15px 32px 0; }
  .hero__visual { width: 38%; }
  .hero__person { max-height: 560px; }
  .gallery__grid {
    gap: 32px;
  }
  .system__layout {
    gap: 32px;
  }
  .form__layout {
    gap: 48px;
  }
}

/* ── Tablet (768-1023px) ── */
@media (max-width: 1023px) {
  /* Typography */
  h1 { font-size: 36px; }
  h2 { font-size: 28px; }
  h3 { font-size: 22px; }

  .section-title {
    font-size: 28px;
  }

  /* GNB */
  .gnb__logo-text {
    font-size: 15px;
  }
  .gnb__sns-link {
    width: 36px;
    height: 36px;
  }

  /* Hero */
  .hero__content { padding: 80px 24px 0; }
  .hero__visual { width: 36%; }
  .hero__person { max-height: 380px; }

  /* Admission */
  .admission__big-number {
    font-size: 72px;
  }
  .bar-chart-group {
    height: 160px;
  }

  /* Certificate */
  .certificate__grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .certificate__big-number {
    font-size: 72px;
  }

  /* Reviews masonry → 2 columns */
  .review-masonry {
    column-count: 2;
  }

  /* System layout → stack */
  .system__layout {
    flex-direction: column;
  }
  .system__tabs {
    width: 100%;
    flex-direction: row;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .system__tab-btn {
    border-left: none;
    border-bottom: 4px solid transparent;
    border-radius: 16px 16px 0 0;
    padding: 16px 24px;
    white-space: nowrap;
    min-width: auto;
  }
  .system__tab-btn.active {
    border-bottom-color: var(--color-primary);
    border-left-color: transparent;
  }
  .system__tab-arrow {
    display: none;
  }
  .system__img {
    height: 400px;
  }

  /* Gallery → 3 columns */
  .gallery__grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
  }

  /* Form → stack */
  .form__layout {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  /* Footer */
  .footer__grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  .footer__company {
    grid-column: 1 / -1;
  }

  /* Partners */
  .partner-swiper.swiper-fallback {
    grid-template-columns: repeat(4, 1fr) !important;
  }

}

/* ── Mobile (≤767px) ── */
@media (max-width: 767px) {
  /* Global */
  .container {
    padding: 0 16px;
  }

  /* Typography */
  h1 { font-size: 28px; }
  h2 { font-size: 24px; }
  h3 { font-size: 20px; }

  .section-title {
    font-size: 24px;
	word-break: keep-all;
  }
  .section-subtitle {
    font-size: 15px;
  }

  /* GNB */
  .gnb {
    height: 56px;
  }
  .gnb__logo-icon {
    width: 32px;
    height: 32px;
  }
  .gnb__logo-icon svg {
    width: 18px;
    height: 18px;
  }
  .gnb__logo-text {
    font-size: 14px;
  }
  .gnb__sns {
    gap: 4px;
  }
  .gnb__sns-link {
    width: 32px;
    height: 32px;
  }
  .gnb__sns-link svg {
    width: 16px;
    height: 16px;
  }

  /* Hero */
  .section--hero { min-height: auto; }
  .site-header__inner { padding: 12px 16px; }
  .site-header.scrolled .site-header__inner { padding: 8px 16px; }
  .site-header__logo img { height: 36px; }
  .site-header__social-link { width: 30px; height: 30px; }
  .site-header__social-link svg { width: 16px; height: 16px; }
  .site-header__social { gap: 8px; }
  .hero__content {
    flex-direction: column;
    padding: 72px 20px 0;
    align-items: stretch;
    min-height: auto;
  }
  .hero__text { padding-bottom: 0; }
  .hero__line1, .hero__line2 { font-size: 36px; }
  .hero__script { font-size: 28px; }
  .hero__subtitle { font-size: 20px; margin-top: 12px; }
  .hero__visual { width: 100%; justify-content: center; }
  .hero__person { max-height: 320px; margin-top: 0; width: 100%; margin-left: 0; }

  /* Admission */
  .admission__hero {
    padding: 80px 0 48px;
  }
  .admission__wreaths {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    justify-items: center;
    max-width: 320px;
    margin: 0 auto;
  }
  .admission__wreath-item {
    width: 150px;
    height: 150px;
  }
  .admission__wreath-item:last-child {
    grid-column: 1 / -1;
  }
  .admission__badge-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    padding: 20px 16px;
  }
  .admission__big-number {
    font-size: 56px;
  }
  .admission__big-label {
    font-size: 24px;
  }
  .admission__chart {
    padding: 24px 16px;
  }
  .bar-chart-group {
    height: 140px;
    gap: 8px;
    padding: 0 8px;
  }
  .bar-label {
    font-size: 12px;
  }
  .bar-year {
    font-size: 12px;
  }
  .admission__badges-section {
    padding: 48px 0;
  }
  .admission__badge-grid {
    gap: 8px;
  }
  .badge {
    font-size: 12px;
    padding: 6px 12px;
  }

  /* Q&A */
  .section--qa {
    padding: 48px 0;
  }
  .qa__card-inner {
    flex-direction: column;
  }
  .qa__profile {
    width: 100%;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 24px 20px;
    border-right: none;
    border-bottom: 1px solid rgba(233,30,140,0.08);
  }
  .qa__photo {
    width: 240px;
  }
  .qa__name {
    margin-top: 0;
    text-align: center;
  }
  .qa__slides {
    padding: 20px;
  }
  .qa-swiper-prev { left: 4px; }
  .qa-swiper-next { right: 4px; }
  .qa__slide-a {
    font-size: 14px;
  }
  .tab-group {
    flex-direction: column;
    gap: 2px;
  }
  .tab-btn {
    padding: 10px 16px;
    font-size: 13px;
  }

  /* Certificate */
  .certificate__content {
    padding: 80px 0 48px;
  }
  .certificate__big-number {
    font-size: 56px;
  }
  .certificate__grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .certificate__chart {
    padding: 24px 16px;
  }

  /* Reviews */
  .section--reviews {
    padding: 48px 0;
  }
  /* 모바일: Masonry 숨기고 Swiper 표시 */
  .review-masonry {
    display: none;
  }
  .review-swiper {
    display: block;
  }

  /* Benefits */
  .section--benefits {
    padding: 48px 0;
  }
  .benefits__card {
    padding: 12px;
  }
  .benefits__img {
    min-height: 250px;
    border-radius: 16px;
  }
  .tab-group[role="tablist"] {
    flex-direction: column;
    display: flex;
  }

  /* Education System */
  .section--system {
    padding: 48px 0;
  }
  .system__accent-line {
    width: 4px;
  }
  .system__layout {
    flex-direction: column;
    gap: 24px;
  }
  .system__tabs {
    width: 100%;
    flex-direction: column;
    gap: 4px;
  }
  .system__tab-btn {
    border-left: 4px solid transparent;
    border-bottom: none;
    border-radius: 0 12px 12px 0;
    padding: 14px 16px;
    font-size: 16px;
  }
  .system__tab-btn.active {
    border-left-color: var(--color-primary);
  }
  .system__tab-arrow {
    display: inline;
  }
  .system__img {
    height: 280px;
  }

  /* Gallery → 2 columns */
  .gallery__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
  .section--gallery {
    padding: 48px 0;
  }
  .polaroid {
    padding: 8px;
    padding-bottom: 32px;
  }
  .polaroid__caption {
    font-size: 12px;
    margin-top: 8px;
  }

  /* Form */
  .section--form {
    padding: 48px 0;
  }
  .form__layout {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .form__card {
    padding: 24px;
    border-radius: 20px;
  }
  .form__consent-btns {
    flex-direction: column;
  }
  .form__trust-badge {
    padding: 16px;
  }

  /* Partners */
  .section--partners {
    padding: 48px 0;
  }
  .partner-swiper.swiper-fallback {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 16px;
  }
  .partner-logo {
    max-height: 40px;
  }

  /* Footer */
  .footer {
    padding: 40px 0;
  }
  .footer__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .footer__heading {
    font-size: 16px;
  }
  .footer__info p {
    font-size: 13px;
  }

  /* Mobile CTA bottom padding — prevent content from being obscured */
  body {
    padding-bottom: 72px;
  }

  /* Lightbox adjustments */
  .lightbox-close {
    top: 12px;
    right: 12px;
    width: 40px;
    height: 40px;
    font-size: 20px;
  }
  .lightbox-prev,
  .lightbox-next {
    width: 36px;
    height: 36px;
    font-size: 20px;
  }
  .lightbox-prev {
    left: 8px;
  }
  .lightbox-next {
    right: 8px;
  }

  /* Marquee pills smaller on mobile */
  .marquee-pill {
    font-size: 13px;
    padding: 7px 16px;
  }

  /* Benefits section title line-height fix */
  .section--benefits .section-title {
    line-height: 1.45;
  }

  /* Wave dividers smaller */
  .wave-divider svg {
    height: 40px;
  }
}

/* ── Extra Small Mobile (≤375px) ── */
@media (max-width: 375px) {
  .hero__heading {
    font-size: 26px;
  }
  .admission__big-number,
  .certificate__big-number {
    font-size: 44px;
  }
  .gallery__grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .bar-chart-group {
    height: 120px;
  }
  .tab-btn {
    font-size: 12px;
    padding: 8px 12px;
  }
}
