/*
 * 지역통합플랫폼 관문 — Google 인덱스형 스테이지 + below-fold (v9.0)
 * SSOT: layout.css --fs-* · --news-page-inset-x* · --fv4-max
 */

/* ── Google 인덱스 스테이지 (above the fold) ── */
.gw-page.gw-google-layout {
  max-width: none;
  padding-bottom: 0;
  background: #fff;
}

.gw-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: min(72vh, 640px);
  padding: clamp(1.5rem, 5vh, 3rem) var(--news-page-inset-x, 16px) clamp(1rem, 3vh, 2rem);
  box-sizing: border-box;
  text-align: center;
}

.gw-brand {
  margin-bottom: clamp(1.25rem, 3vh, 1.75rem);
}

.gw-brand-logo {
  display: block;
  width: auto;
  max-width: min(272px, 72vw);
  height: auto;
  max-height: 92px;
  object-fit: contain;
  margin: 0 auto;
}

.gw-brand-wordmark {
  margin: 0;
  font-size: var(--fs-hero);
  font-weight: 900;
  letter-spacing: -0.04em;
  color: #0f2f56;
  line-height: 1.2;
}

.gw-brand-tagline {
  margin: 8px 0 0;
  font-size: var(--fs-md);
  font-weight: 600;
  color: #64748b;
}

.gw-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.gw-search-google {
  width: 100%;
  max-width: 584px;
  margin: 0 auto;
}

.gw-search-bar {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  min-height: 46px;
  padding: 4px 6px 4px 4px;
  background: #fff;
  border: 1px solid #dfe1e5;
  border-radius: 24px;
  box-sizing: border-box;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
}

.gw-search-bar:hover,
.gw-search-bar.is-focus {
  border-color: transparent;
  box-shadow: 0 2px 8px rgba(32, 33, 36, 0.3);
  outline: none;
}

.gw-search-bar .gw-search-scope-btn {
  min-height: 36px;
  padding: 0 12px;
  background: #f1f5f9;
  font-size: var(--fs-sm);
}

.gw-search-bar .gw-search-input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 38px;
  padding: 0 8px;
  border: 0;
  outline: 0;
  font-size: var(--fs-base);
  background: transparent;
}

.gw-search-lens {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  color: #4285f4;
}

.gw-search-lens:hover {
  background: #f1f3f4;
}

.gw-search-lens-ico {
  display: block;
  width: 20px;
  height: 20px;
  background: currentColor;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z'/%3E%3C/svg%3E") center / contain no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.gw-search-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: clamp(1rem, 2.5vh, 1.75rem);
}

.gw-act-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 20px;
  border: 1px solid #dadce0;
  border-radius: 4px;
  background: #f8f9fa;
  color: #3c4043;
  font-size: var(--fs-sm);
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s, box-shadow 0.12s;
  letter-spacing: 0.01em;
}

.gw-act-btn:hover {
  background: #f1f3f4;
  border-color: #c6c6c6;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.08);
  color: #202124;
}

.gw-stage .gw-keywords {
  margin-top: clamp(1rem, 2vh, 1.5rem);
}

.gw-below-fold {
  max-width: var(--fv4-max, 1200px);
  margin: 0 auto;
  padding: 0 var(--news-page-inset-x, 0) 3rem;
  box-sizing: border-box;
  border-top: 1px solid #f1f3f4;
}

.gw-page {
  width: 100%;
  max-width: var(--fv4-max, 1200px);
  margin: 0 auto;
  padding: 0 var(--news-page-inset-x, 0) 3rem;
  box-sizing: border-box;
  font-size: var(--fs-base);
  line-height: 1.5;
  color: #0f172a;
}

.gw-preview-flag {
  position: sticky;
  top: 0;
  z-index: 500;
  background: #14155f;
  color: #fff;
  text-align: center;
  font-size: var(--fs-xs);
  font-weight: 700;
  padding: 6px 12px;
}

/* ── 섹션 공통 ── */
.gw-section { margin-top: 2.5rem; }
.gw-sec-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 1rem;
}
.gw-sec-head h2,
.gw-sec-head h3 {
  margin: 0;
  font-size: var(--fs-xl);
  font-weight: 800;
  color: #0f2f56;
  letter-spacing: -0.02em;
}
.gw-sec-more {
  flex: 0 0 auto;
  font-size: var(--fs-sm);
  font-weight: 700;
  color: var(--fv4-brand, #0a4d8c);
  text-decoration: none;
  white-space: nowrap;
}
.gw-sec-more:hover { text-decoration: underline; }

.gw-empty {
  padding: 1.25rem 1rem;
  border: 1px dashed #cbd5e1;
  border-radius: 12px;
  background: #f8fafc;
  color: #64748b;
  font-size: var(--fs-sm);
  text-align: center;
}

/* ── 히어로 · 통합검색 (레거시 — below-fold 호환) ── */
.gw-hero {
  margin-top: 1.25rem;
  padding: clamp(1.5rem, 4vw, 2.5rem) clamp(1rem, 3vw, 2rem);
  border-radius: 20px;
  background:
    radial-gradient(120% 90% at 0% 0%, color-mix(in srgb, var(--gw-c1, #24aebe) 18%, #fff) 0%, transparent 55%),
    radial-gradient(120% 90% at 100% 0%, color-mix(in srgb, var(--gw-c3, #d83269) 14%, #fff) 0%, transparent 55%),
    linear-gradient(180deg, #fff 0%, #f4f9fc 100%);
  border: 1px solid #e2e8f0;
  box-shadow: 0 12px 32px rgba(15, 47, 86, 0.06);
  text-align: center;
}
.gw-hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 auto 12px;
  padding: 6px 14px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid color-mix(in srgb, var(--gw-c1) 30%, #e2e8f0);
  font-size: var(--fs-sm);
  font-weight: 700;
  color: #0a4d8c;
}
.gw-hero h1 {
  margin: 0 0 1.25rem;
  font-size: var(--fs-hero);
  font-weight: 900;
  line-height: 1.35;
  color: #0f2f56;
  letter-spacing: -0.03em;
}
.gw-search {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 8px;
  max-width: 640px;
  margin: 0 auto;
  padding: 6px;
  background: #fff;
  border-radius: 999px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 16px rgba(15, 47, 86, 0.08);
}
.gw-search-scope {
  position: relative;
  flex: 0 0 auto;
}
.gw-search-scope-btn {
  display: flex;
  align-items: center;
  gap: 4px;
  min-height: 44px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  background: #f1f5f9;
  font-size: var(--fs-sm);
  font-weight: 700;
  color: #334155;
  cursor: pointer;
  white-space: nowrap;
}
.gw-search-scope.on .gw-search-scope-btn { background: #e0e7ff; color: #1e3a8a; }
.gw-search-scope-list {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 40;
  min-width: 160px;
  max-height: 240px;
  overflow: auto;
  margin: 0;
  padding: 6px;
  list-style: none;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(15, 47, 86, 0.12);
}
.gw-search-scope.on .gw-search-scope-list { display: block; }
.gw-search-scope-list label {
  display: block;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: var(--fs-sm);
  cursor: pointer;
}
.gw-search-scope-list label:hover { background: #f1f5f9; }
.gw-search-input {
  flex: 1 1 180px;
  min-width: 0;
  min-height: 44px;
  padding: 0 14px;
  border: 0;
  outline: 0;
  font-size: var(--fs-base);
  background: transparent;
}
.gw-search-submit {
  flex: 0 0 auto;
  min-height: 44px;
  padding: 0 20px;
  border: 0;
  border-radius: 999px;
  background: var(--fv4-brand, #0a4d8c);
  color: #fff;
  font-size: var(--fs-sm);
  font-weight: 800;
  cursor: pointer;
}
.gw-search-submit:hover { background: #075985; }
.gw-keywords {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 14px;
}
.gw-kw {
  border: 1px solid #dadce0;
  background: #fff;
  border-radius: 999px;
  padding: 7px 14px;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: #3c4043;
  cursor: pointer;
  transition: border-color 0.12s, color 0.12s, box-shadow 0.12s;
}
.gw-kw:hover {
  border-color: #4285f4;
  color: #1a73e8;
  box-shadow: 0 1px 3px rgba(66,133,244,.15);
}

/* ── 14포털 그리드 ── */
.gw-portals {
  margin-top: 2rem;
  padding: 1.25rem 1rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  box-shadow: 0 4px 16px rgba(15, 47, 86, 0.04);
}
.gw-portals-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 10px;
}
.gw-portal {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 10px 6px;
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: background 0.15s, transform 0.15s;
}
.gw-portal:hover {
  background: color-mix(in srgb, var(--pc, #0a4d8c) 8%, #fff);
  transform: translateY(-2px);
}
.gw-portal-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--pc, #0a4d8c) 14%, #fff);
  border: 2px solid var(--pc, #0a4d8c);
  font-size: var(--fs-sm);
  font-weight: 900;
  color: var(--pc, #0a4d8c);
}
.gw-portal-name {
  font-size: var(--fs-xs);
  font-weight: 700;
  color: #334155;
  text-align: center;
  line-height: 1.2;
  word-break: keep-all;
}
.gw-portal-stat {
  font-size: var(--fs-xs);
  font-weight: 600;
  color: #64748b;
}

/* ── 지역 3포털 ── */
.gw-regions-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.gw-region {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 1.1rem 1.2rem;
  border-radius: 14px;
  text-decoration: none;
  color: #fff;
  background: var(--rc, #24aebe);
  box-shadow: 0 8px 20px color-mix(in srgb, var(--rc, #24aebe) 35%, transparent);
  transition: transform 0.15s;
}
.gw-region:hover { transform: translateY(-3px); }
.gw-region strong { font-size: var(--fs-lg); font-weight: 900; }
.gw-region em {
  font-style: normal;
  font-size: var(--fs-sm);
  opacity: 0.92;
  line-height: 1.35;
}
.gw-region-go {
  margin-top: auto;
  font-size: var(--fs-sm);
  font-weight: 700;
  opacity: 0.95;
}

/* ── 홍보 슬라이드 (실이미지만) ── */
.gw-promo-track-wrap { position: relative; }
.gw-promo-track {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 4px;
}
.gw-promo-track::-webkit-scrollbar { display: none; }
.gw-promo-item {
  flex: 0 0 clamp(260px, 32%, 360px);
  scroll-snap-align: start;
  border-radius: 14px;
  overflow: hidden;
  text-decoration: none;
  color: #fff;
  position: relative;
  aspect-ratio: 16 / 9;
  background: #cbd5e1;
}
.gw-promo-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.gw-promo-cap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 12px 14px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.72));
  font-size: var(--fs-sm);
  font-weight: 700;
  line-height: 1.35;
}

/* ── 뉴스 캐러셀 ── */
.gw-news-wrap { position: relative; }
.gw-news-track {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 8px;
}
.gw-news-track::-webkit-scrollbar { display: none; }
.gw-news-card {
  flex: 0 0 clamp(220px, 28vw, 280px);
  scroll-snap-align: start;
  text-decoration: none;
  color: inherit;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  background: #fff;
  transition: box-shadow 0.15s;
}
.gw-news-card:hover { box-shadow: 0 8px 24px rgba(15, 47, 86, 0.1); }
.gw-news-thumb {
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, var(--gw-c1), var(--gw-c2));
}
.gw-news-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gw-news-body { padding: 12px 14px; }
.gw-news-date { font-size: var(--fs-xs); color: #94a3b8; }
.gw-news-title {
  margin: 6px 0 0;
  font-size: var(--fs-base);
  font-weight: 700;
  color: #0f2f56;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ── 핵심 서비스 탭 ── */
.gw-svc-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 1rem;
}
.gw-svc-tab {
  border: 1px solid #e2e8f0;
  background: #fff;
  border-radius: 999px;
  padding: 8px 14px;
  font-size: var(--fs-sm);
  font-weight: 700;
  color: #475569;
  cursor: pointer;
}
.gw-svc-tab.on {
  background: var(--fv4-brand, #0a4d8c);
  border-color: var(--fv4-brand, #0a4d8c);
  color: #fff;
}
.gw-svc-panel { display: none; }
.gw-svc-panel.on { display: block; }
.gw-svc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
}
.gw-svc-link {
  display: block;
  padding: 14px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s, background 0.15s;
}
.gw-svc-link:hover {
  border-color: var(--fv4-brand, #0a4d8c);
  background: #f8fafc;
}
.gw-svc-name { font-size: var(--fs-base); font-weight: 700; color: #0f2f56; }
.gw-svc-from { font-size: var(--fs-xs); color: #64748b; margin-top: 4px; }

/* ── 추천 콘텐츠 ── */
.gw-feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.gw-feature {
  display: block;
  padding: 1rem;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: #fff;
  text-decoration: none;
  color: inherit;
}
.gw-feature:hover { border-color: #94a3b8; }
.gw-feature-badge {
  display: inline-block;
  font-size: var(--fs-xs);
  font-weight: 800;
  color: var(--fv4-brand, #0a4d8c);
  margin-bottom: 6px;
}
.gw-feature-title {
  margin: 0;
  font-size: var(--fs-base);
  font-weight: 700;
  line-height: 1.4;
  color: #0f2f56;
}

/* ── 공지 + 새소식 2열 ── */
.gw-dual {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.gw-list { display: flex; flex-direction: column; gap: 0; }
.gw-list-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #eef2f7;
  text-decoration: none;
  color: inherit;
}
.gw-list-row:last-child { border-bottom: 0; }
.gw-list-row:hover .gw-list-title { color: var(--fv4-brand, #0a4d8c); }
.gw-list-title {
  flex: 1 1 auto;
  min-width: 0;
  font-size: var(--fs-base);
  font-weight: 600;
  color: #1e293b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.gw-list-date {
  flex: 0 0 auto;
  font-size: var(--fs-xs);
  color: #94a3b8;
}

/* ── 슬라이더 화살표 ── */
.gw-slider-nav {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 10px;
}
.gw-slider-btn {
  width: 36px;
  height: 36px;
  border: 1px solid #e2e8f0;
  border-radius: 50%;
  background: #fff;
  color: #334155;
  cursor: pointer;
  font-size: var(--fs-sm);
}
.gw-slider-btn:hover { background: #f1f5f9; }

@media (max-width: 768px) {
  .gw-stage {
    min-height: min(64vh, 520px);
    padding-left: var(--news-page-inset-x-md, 10px);
    padding-right: var(--news-page-inset-x-md, 10px);
  }
  .gw-below-fold {
    padding-left: var(--news-page-inset-x-md, 10px);
    padding-right: var(--news-page-inset-x-md, 10px);
  }
  .gw-search-bar {
    flex-wrap: wrap;
    border-radius: 16px;
    padding: 8px;
  }
  .gw-search-bar .gw-search-scope,
  .gw-search-bar .gw-search-scope-btn {
    width: 100%;
  }
  .gw-search-bar .gw-search-input {
    width: 100%;
    flex: 1 1 100%;
    padding: 8px 10px;
  }
  .gw-search-lens {
    margin-left: auto;
  }
  .gw-search-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .gw-act-btn {
    width: 100%;
    border-radius: 8px;
  }
  .gw-brand-wordmark { font-size: var(--fs-2xl); }
  .gw-page {
    padding-left: var(--news-page-inset-x-md, 10px);
    padding-right: var(--news-page-inset-x-md, 10px);
  }
  .gw-hero h1 { font-size: var(--fs-xl); }
  .gw-search { border-radius: 16px; flex-direction: column; align-items: stretch; }
  .gw-search-scope,
  .gw-search-scope-btn { width: 100%; }
  .gw-search-submit { width: 100%; border-radius: 12px; }
  .gw-portals-grid { grid-template-columns: repeat(4, 1fr); gap: 6px; }
  .gw-portal-mark { width: 2.4rem; height: 2.4rem; font-size: var(--fs-xs); }
  .gw-regions-grid { grid-template-columns: 1fr; }
  .gw-feature-grid { grid-template-columns: 1fr; }
  .gw-dual { grid-template-columns: 1fr; }
  .gw-promo-item { flex: 0 0 calc(100% - 4px); }
}

@media (max-width: 480px) {
  .gw-stage {
    padding-left: var(--news-page-inset-x-sm, 8px);
    padding-right: var(--news-page-inset-x-sm, 8px);
  }
  .gw-below-fold {
    padding-left: var(--news-page-inset-x-sm, 8px);
    padding-right: var(--news-page-inset-x-sm, 8px);
  }
  .gw-page {
    padding-left: var(--news-page-inset-x-sm, 8px);
    padding-right: var(--news-page-inset-x-sm, 8px);
  }
  .gw-portals-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ══ Google 관문 — /portal/index.php · domain index (단일 스크롤 100%) ══ */
html.gw-google-html {
  height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
  scroll-behavior: auto;
  -webkit-text-size-adjust: 100%;
}

body.gw-google-root {
  min-height: 100%;
  min-height: 100dvh;
  margin: 0;
  display: flex;
  flex-direction: column;
  overflow: visible;
  background: #fff;
  color: #202124;
  font-family: Arial, Helvetica, sans-serif;
  font-size: var(--fs-base, 16px);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.gw-g-top {
  flex: 0 0 auto;
  padding: 6px 16px;
}

.gw-g-top-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 4px 6px;
}

.gw-g-icon-btn,
.gw-g-account-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 40px;
  min-width: 40px;
  padding: 0 10px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #5f6368;
  font-size: var(--fs-sm, 15px);
  font-family: inherit;
  cursor: pointer;
  list-style: none;
  text-decoration: none;
  white-space: nowrap;
}

.gw-g-icon-btn:hover,
.gw-g-account-btn:hover {
  background: #f1f3f4;
}

.gw-g-dd { position: relative; }
.gw-g-dd > summary { list-style: none; }
.gw-g-dd > summary::-webkit-details-marker { display: none; }

.gw-g-dd-panel {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 80;
  margin: 0;
  padding: 0;
  list-style: none;
  background: #fff;
  border: 1px solid #dadce0;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(32, 33, 36, 0.18);
}

.gw-g-dd-title {
  margin: 0;
  padding: 12px 16px 8px;
  font-size: var(--fs-sm, 15px);
  font-weight: 600;
  color: #5f6368;
}

.gw-g-dots {
  display: grid;
  grid-template-columns: repeat(3, 4px);
  gap: 3px;
  width: 18px;
  height: 18px;
}

.gw-g-dots span {
  display: block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #5f6368;
}

.gw-g-apps-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(88px, 1fr));
  gap: 8px;
  padding: 4px 12px 14px;
  max-height: 360px;
  overflow-y: auto;
}

.gw-g-app {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 12px 8px;
  border-radius: 8px;
  text-decoration: none;
  color: #202124;
}

.gw-g-app:hover { background: #f1f3f4; }

.gw-g-app-ico {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--app-c, #1a73e8) 14%, #fff);
  color: var(--app-c, #1a73e8);
  font-size: var(--fs-md, 17px);
  font-weight: 700;
}

.gw-g-app-name {
  font-size: var(--fs-sm, 15px);
  text-align: center;
  line-height: 1.25;
}

.gw-g-dd-panel--apps { min-width: 300px; }

.gw-g-portal-btn {
  border-radius: 20px;
  min-width: auto;
  padding: 0 12px;
}

.gw-g-portal-btn-label {
  font-size: var(--fs-sm, 15px);
  font-weight: 500;
  color: #3c4043;
}

.gw-g-caret {
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid #5f6368;
}

.gw-g-portal-list {
  margin: 0;
  padding: 6px;
  list-style: none;
  min-width: 200px;
  max-height: 320px;
  overflow-y: auto;
}

.gw-g-portal-item {
  display: block;
  padding: 10px 12px;
  border-radius: 6px;
  font-size: var(--fs-sm, 15px);
  color: #202124;
  text-decoration: none;
}

.gw-g-portal-item:hover,
.gw-g-portal-item.is-on { background: #e8f0fe; color: #1a73e8; }

.gw-g-lang-btn { border-radius: 20px; }

.gw-g-flag {
  font-size: 18px;
  line-height: 1;
}

.gw-g-lang-code {
  font-size: var(--fs-sm, 15px);
  font-weight: 600;
  color: #3c4043;
}

.gw-g-dd-panel--lang {
  min-width: 180px;
  padding: 6px;
}

.gw-g-lang-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 6px;
  font-size: var(--fs-sm, 15px);
  color: #202124;
  text-decoration: none;
}

.gw-g-lang-item:hover,
.gw-g-lang-item.is-on { background: #f1f3f4; }

.gw-g-account-btn {
  border-radius: 24px;
  padding-right: 14px;
}

.gw-g-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #1a73e8;
  color: #fff;
  font-size: var(--fs-sm, 15px);
  font-weight: 700;
}

.gw-g-account-name {
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: var(--fs-sm, 15px);
  font-weight: 500;
  color: #3c4043;
}

.gw-g-dd-panel--account {
  min-width: 200px;
  padding: 12px;
}

.gw-g-dd-user {
  margin: 0 0 10px;
  font-size: var(--fs-sm, 15px);
  font-weight: 600;
  color: #202124;
}

.gw-g-dd-link {
  display: block;
  padding: 8px 10px;
  border-radius: 6px;
  font-size: var(--fs-sm, 15px);
  color: #1a73e8;
  text-decoration: none;
}

.gw-g-dd-link:hover { background: #e8f0fe; }

.gw-g-quick {
  width: 100%;
  max-width: 584px;
  margin: 20px auto 0;
  padding: 0 16px;
  box-sizing: border-box;
  text-align: center;
}

.gw-g-quick-lbl {
  display: block;
  margin-bottom: 10px;
  font-size: var(--fs-sm, 15px);
  color: #70757a;
  font-weight: 600;
}

.gw-g-quick-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.gw-g-quick-chip {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid #dadce0;
  border-radius: 18px;
  background: #fff;
  color: #3c4043;
  font-size: var(--fs-sm, 15px);
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
}

.gw-g-quick-chip:hover {
  background: #f1f3f4;
  border-color: #bdc1c6;
}

.gw-search-tool {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  flex-shrink: 0;
  text-decoration: none;
}

.gw-search-tool:hover { background: #f1f3f4; }

.gw-g-top-link {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 0 12px;
  font-size: var(--fs-sm, 15px);
  color: rgba(0, 0, 0, 0.87);
  text-decoration: none;
  border-radius: 4px;
  white-space: nowrap;
}

.gw-g-top-link:hover {
  text-decoration: underline;
}

.gw-g-signin {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  margin-left: 4px;
  padding: 0 24px;
  border-radius: 4px;
  background: #1a73e8;
  color: #fff;
  font-size: var(--fs-sm, 15px);
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}

.gw-g-signin:hover {
  background: #1765cc;
  box-shadow: 0 1px 3px rgba(26, 115, 232, 0.4);
  text-decoration: none;
}

.gw-g-lang { position: relative; }
.gw-g-lang summary { list-style: none; cursor: pointer; }
.gw-g-lang summary::-webkit-details-marker { display: none; }

.gw-g-lang-list {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  z-index: 50;
  min-width: 140px;
  margin: 0;
  padding: 6px;
  list-style: none;
  background: #fff;
  border: 1px solid #dadce0;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(32, 33, 36, 0.15);
}

.gw-g-lang-list a {
  display: block;
  padding: 8px 10px;
  border-radius: 4px;
  font-size: var(--fs-sm, 15px);
  color: #202124;
  text-decoration: none;
}

.gw-g-lang-list a:hover,
.gw-g-lang-list a[aria-current="true"] { background: #f1f3f4; }

.gw-g-main {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 16px 48px;
  box-sizing: border-box;
}

.gw-g-center {
  width: 100%;
  max-width: 584px;
  text-align: center;
}

.gw-google-root .gw-brand {
  margin-bottom: 28px;
}

.gw-google-root .gw-brand-logo {
  display: block;
  width: auto;
  max-width: min(272px, 72vw);
  height: auto;
  max-height: 92px;
  object-fit: contain;
  margin: 0 auto;
}

.gw-google-root .gw-brand-wordmark {
  margin: 0;
  font-size: var(--fs-hero, 32px);
  font-weight: 400;
  letter-spacing: -0.02em;
  color: #202124;
  line-height: 1.2;
}

.gw-google-root .gw-search-google {
  position: relative;
  width: 100%;
  max-width: 584px;
  margin: 0 auto;
}

.gw-google-root .gw-search-bar {
  display: flex;
  align-items: center;
  gap: 0;
  width: 100%;
  min-height: 44px;
  padding: 0 8px 0 14px;
  background: #fff;
  border: 1px solid #dfe1e5;
  border-radius: 24px;
  box-sizing: border-box;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
}

.gw-google-root .gw-search-bar:hover,
.gw-google-root .gw-search-bar.is-focus {
  border-color: transparent;
  box-shadow: 0 1px 6px rgba(32, 33, 36, 0.28);
  outline: none;
}

.gw-google-root .gw-search-input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 44px;
  padding: 0 8px;
  border: 0;
  outline: 0;
  font-size: var(--fs-base, 16px);
  background: transparent;
  color: #202124;
}

.gw-google-root .gw-search-tools {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.gw-search-ico {
  display: block;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  opacity: 0.7;
}

.gw-search-ico--lens {
  margin-right: 4px;
  background: #9aa0a6;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z'/%3E%3C/svg%3E") center / contain no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.gw-search-ico--mic {
  background: #4285f4;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M12 14c1.66 0 3-1.34 3-3V5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3zm5.91-3c-.49 0-.9.36-.98.85C16.52 14.64 14.48 17 12 17s-4.52-2.36-4.93-5.15c-.08-.49-.49-.85-.98-.85-.61 0-1.09.54-1 1.14.49 3.31 3.28 5.86 6.91 5.86s6.42-2.55 6.91-5.86c.1-.6-.39-1.14-1-1.14z'/%3E%3C/svg%3E") center / contain no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M12 14c1.66 0 3-1.34 3-3V5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3zm5.91-3c-.49 0-.9.36-.98.85C16.52 14.64 14.48 17 12 17s-4.52-2.36-4.93-5.15c-.08-.49-.49-.85-.98-.85-.61 0-1.09.54-1 1.14.49 3.31 3.28 5.86 6.91 5.86s6.42-2.55 6.91-5.86c.1-.6-.39-1.14-1-1.14z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.gw-search-ico--cam {
  background: #9aa0a6;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M9.4 10.5l4.67-2.5c0 .5.4.9.9.9h3.5c.55 0 1 .45 1 1v7c0 .55-.45 1-1 1h-12c-.55 0-1-.45-1-1v-9.5l3.03 2.1z'/%3E%3C/svg%3E") center / contain no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M9.4 10.5l4.67-2.5c0 .5.4.9.9.9h3.5c.55 0 1 .45 1 1v7c0 .55-.45 1-1 1h-12c-.55 0-1-.45-1-1v-9.5l3.03 2.1z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.gw-google-root .gw-search-lens {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  color: #4285f4;
}

.gw-google-root .gw-search-lens:hover { background: #f1f3f4; }

.gw-g-btn-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 26px;
}

.gw-g-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 16px;
  border: 1px solid #f8f9fa;
  border-radius: 4px;
  background: #f8f9fa;
  color: #3c4043;
  font-size: var(--fs-sm, 15px);
  font-family: inherit;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.12s, box-shadow 0.12s;
}

.gw-g-btn:hover {
  border-color: #dadce0;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.1);
  color: #202124;
}

.gw-suggest {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  z-index: 100;
  background: #fff;
  border: 1px solid #dadce0;
  border-radius: 0 0 24px 24px;
  box-shadow: 0 4px 16px rgba(32, 33, 36, 0.2);
  overflow: hidden;
  text-align: left;
}

.gw-suggest-item {
  display: block;
  width: 100%;
  padding: 10px 20px;
  border: 0;
  border-top: 1px solid #f1f3f4;
  background: none;
  font-size: var(--fs-sm, 15px);
  color: #202124;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-sizing: border-box;
}

.gw-suggest-item:first-child { border-top: 0; }
.gw-suggest-item:hover,
.gw-suggest-item:focus { background: #f1f3f4; outline: none; }

.gw-suggest-ico {
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 10px;
  vertical-align: -2px;
  background: #9aa0a6;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z'/%3E%3C/svg%3E") center / contain no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.gw-g-foot {
  flex: 0 0 auto;
  margin-top: auto;
  background: #f2f2f2;
  border-top: 1px solid #dadce0;
}

.gw-g-foot-region {
  padding: 15px 30px;
  border-bottom: 1px solid #dadce0;
  font-size: var(--fs-sm, 15px);
  color: #70757a;
}

.gw-g-foot-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding: 15px 20px;
}

.gw-g-foot-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 24px;
}

.gw-g-foot-nav a {
  font-size: var(--fs-sm, 15px);
  color: #70757a;
  text-decoration: none;
  white-space: nowrap;
}

.gw-g-foot-nav a:hover { text-decoration: underline; }

@media (max-width: 768px) {
  .gw-g-top { padding: 4px 8px; }
  .gw-g-signin { padding: 0 16px; min-height: 36px; }
  .gw-g-main { align-items: flex-start; padding-top: clamp(48px, 12vh, 120px); }
  .gw-google-root .gw-brand { margin-bottom: 24px; }
  .gw-google-root .gw-brand-logo { max-width: min(220px, 62vw); max-height: 76px; }
  .gw-search-ico--lens { display: none; }
  .gw-g-account-name,
  .gw-g-portal-btn-label,
  .gw-g-lang-code { display: none; }
  .gw-g-foot-region { padding: 12px 16px; }
  .gw-g-foot-row { flex-direction: column; align-items: center; padding: 12px 16px 20px; }
  .gw-g-foot-nav { justify-content: center; }
}

@media (max-width: 480px) {
  .gw-g-top-nav { gap: 0 2px; }
  .gw-g-btn-row { gap: 10px; margin-top: 22px; }
  .gw-g-btn { min-height: 40px; padding: 0 14px; }
  .gw-g-apps-grid { grid-template-columns: repeat(3, minmax(72px, 1fr)); }
}

/* ══ Google 검색 SERP — search/site.php (L14 없음 · 독립 화면) ══ */
/* 반응형 브레이크포인트 SSOT */
:root {
  --gw-bp-mobile-max: 779px;
  --gw-bp-compact-max: 959px;
  --gw-bp-wide-min: 960px;
}

.gw-chrome--mobile {
  display: none;
}

.gw-chrome--desktop {
  display: block;
}

body.gw-serp-root {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  background: #fff;
}

.gw-serp-shell {
  --gw-serp-pad-x: 30px;
  --gw-serp-logo-col: 92px;
  --gw-serp-gap: 16px;
  --gw-serp-content-inset: 180px;
  --gw-serp-result-max: 600px;
  --gw-serp-aside-w: 300px;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
}

/* 상단 — 로고(필수) · 검색 · 우측메뉴 그리드 (겹침 방지) */
.gw-serp-header {
  display: grid;
  grid-template-columns: var(--gw-serp-logo-col) minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--gw-serp-gap);
  padding: 6px var(--gw-serp-pad-x);
  box-sizing: border-box;
}

.gw-g-top--serp {
  position: static;
  padding: 0;
  grid-column: 3;
  justify-self: end;
}

.gw-g-top--serp .gw-g-top-nav {
  flex-wrap: nowrap;
}

.gw-serp-form {
  grid-column: 2;
  position: relative;
  min-width: 0;
  max-width: 692px;
  width: 100%;
}

.gw-serp-logo {
  grid-column: 1;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: var(--gw-serp-logo-col);
  min-width: var(--gw-serp-logo-col);
  height: 44px;
  flex-shrink: 0;
  text-decoration: none;
}

.gw-serp-search-compact {
  display: none;
  grid-column: 2;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid #dfe1e5;
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
  flex-shrink: 0;
}

.gw-serp-search-compact:hover {
  background: #f1f3f4;
}

/* 검색 분기 — 지역(우선) · 포털 · 검색영역 */
.gw-serp-branch-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 20px;
  margin: 0;
  padding: 10px var(--gw-serp-pad-x) 10px var(--gw-serp-content-inset);
  border-bottom: 1px solid #ebebeb;
  background: #f8f9fa;
}

.gw-serp-branch {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
}

.gw-serp-branch-k {
  font-size: var(--fs-sm, 15px);
  color: #70757a;
}

.gw-serp-branch-v {
  font-weight: 700;
}

.gw-serp-branch--region .gw-serp-branch-v {
  font-size: var(--fs-md, 17px);
  color: #1a73e8;
}

.gw-serp-branch--portal .gw-serp-branch-v {
  font-size: var(--fs-sm, 15px);
  color: #9334e6;
}

.gw-serp-branch--domain .gw-serp-branch-v {
  font-size: var(--fs-sm, 15px);
  color: #137333;
}

.gw-serp-item-region {
  margin: 0 0 4px;
  font-size: var(--fs-sm, 15px);
  font-weight: 700;
  color: #1a73e8;
}

/* 관문 홈 광고 */
.gw-home-ad {
  max-width: 728px;
  margin: 0 auto;
  padding: 12px 16px;
  box-sizing: border-box;
}

.gw-home-ad--top {
  padding-top: 8px;
}

.gw-home-ad--bottom {
  padding-bottom: 16px;
}

/* 검색 모달 (좁은 데스크탑) */
.gw-search-modal[hidden] {
  display: none !important;
}

.gw-search-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 72px 16px 16px;
}

.gw-search-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(32, 33, 36, 0.45);
}

.gw-search-modal-panel {
  position: relative;
  width: min(692px, 100%);
  z-index: 1;
}

.gw-search-modal-form {
  display: flex;
  align-items: center;
  gap: 8px;
}

.gw-search-modal-bar {
  flex: 1 1 auto;
  min-width: 0;
}

.gw-search-modal-close {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: #fff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.gw-serp-head-row {
  display: contents;
}

.gw-serp-head-row .gw-serp-logo {
  justify-self: start;
  margin-left: 0;
}

.gw-serp-logo img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.gw-serp-logo-text {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #1a73e8;
  color: #fff;
  font-size: var(--fs-lg, 18px);
  font-weight: 700;
}

.gw-serp-bar {
  border-radius: 24px;
  max-width: none;
}

.gw-serp-clear {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #70757a;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

.gw-serp-clear:hover {
  background: #f1f3f4;
}

.gw-serp-suggest {
  border-radius: 0 0 24px 24px;
}

.gw-serp-region-badge,
.gw-serp-top-ad {
  padding-left: var(--gw-serp-content-inset);
  padding-right: var(--gw-serp-pad-x);
  box-sizing: border-box;
}

.gw-serp-region-badge {
  margin: 0;
  padding-top: 8px;
  font-size: var(--fs-sm, 15px);
  color: #70757a;
}

.gw-serp-top-ad {
  margin-top: 8px;
}

.gw-serp-tabs {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 0 26px;
  margin-top: 4px;
  padding: 0 var(--gw-serp-pad-x) 0 var(--gw-serp-content-inset);
  border-bottom: 1px solid #ebebeb;
  max-width: 100%;
  box-sizing: border-box;
}

.gw-serp-tab {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 2px 10px;
  border-bottom: 3px solid transparent;
  margin-bottom: -1px;
  font-size: var(--fs-sm, 15px);
  color: #5f6368;
  text-decoration: none;
  white-space: nowrap;
}

.gw-serp-tab:hover {
  color: #202124;
}

.gw-serp-tab.is-on {
  color: #1a73e8;
  border-bottom-color: #1a73e8;
  font-weight: 500;
}

.gw-serp-filter {
  position: relative;
  margin-left: auto;
}

.gw-serp-filter summary {
  list-style: none;
  cursor: pointer;
}

.gw-serp-filter summary::-webkit-details-marker {
  display: none;
}

.gw-serp-filter-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 4px);
  z-index: 60;
  min-width: 260px;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid #dadce0;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(32, 33, 36, 0.15);
}

.gw-serp-filter-label {
  margin: 0 0 10px;
  font-size: var(--fs-sm, 15px);
  font-weight: 700;
  color: #202124;
}

.gw-serp-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.gw-serp-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border: 1px solid #dadce0;
  border-radius: 16px;
  font-size: var(--fs-sm, 15px);
  color: #3c4043;
  cursor: pointer;
  user-select: none;
}

.gw-serp-chip input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.gw-serp-chip.is-on {
  background: #e8f0fe;
  border-color: #1a73e8;
  color: #1a73e8;
}

.gw-serp-body {
  flex: 1 1 auto;
  width: 100%;
  box-sizing: border-box;
}

.gw-serp-main {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 18px var(--gw-serp-pad-x) 32px var(--gw-serp-content-inset);
  box-sizing: border-box;
}

.gw-serp-home .gw-serp-main {
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 584px;
  padding: 20px 16px 48px;
}

.gw-serp-home-center {
  width: 100%;
  text-align: center;
}

.gw-serp-home-brand {
  margin-bottom: 24px;
}

.gw-serp-home-hint {
  margin: 0;
  font-size: var(--fs-sm, 15px);
  color: #70757a;
}

.gw-serp-recent {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 24px;
  align-items: center;
}

.gw-serp-recent-lbl {
  font-size: var(--fs-sm, 15px);
  color: #70757a;
  font-weight: 600;
}

.gw-serp-recent a {
  font-size: var(--fs-sm, 15px);
  padding: 6px 14px;
  background: #f1f3f4;
  border-radius: 16px;
  color: #3c4043;
  text-decoration: none;
}

.gw-serp-recent a:hover {
  background: #e8eaed;
}

.gw-serp-recent--home {
  justify-content: center;
  margin: -24px auto 0;
  max-width: 584px;
  padding: 0 16px 16px;
}

.gw-serp-stats {
  margin: 0 0 20px;
  font-size: var(--fs-sm, 15px);
  color: #70757a;
}

.gw-serp-results {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.gw-serp-domain-rule {
  margin: 0;
  border: 0;
  border-top: 1px solid #ebebeb;
  height: 0;
}

.gw-serp-section {
  display: grid;
  grid-template-columns: minmax(0, var(--gw-serp-result-max)) minmax(0, var(--gw-serp-aside-w));
  gap: 0 28px;
  align-items: start;
}

.gw-serp-section-head {
  grid-column: 1 / -1;
  margin: 0 0 12px;
}

.gw-serp-section-col {
  min-width: 0;
  grid-column: 1;
}

.gw-serp-section-title {
  margin: 0;
  font-size: var(--fs-sm, 15px);
  font-weight: 600;
  color: #70757a;
  letter-spacing: 0.01em;
}

.gw-serp-section-aside {
  min-width: 0;
}

.gw-serp-aside-ad {
  position: sticky;
  top: 12px;
}

.gw-serp-inline-ad {
  margin: 20px 0;
}

.gw-serp-item {
  margin-bottom: 28px;
}

.gw-serp-item:last-child {
  margin-bottom: 0;
}

.gw-serp-item-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 4px;
}

.gw-serp-favicon-dot {
  display: block;
  width: 16px;
  height: 16px;
  margin-top: 4px;
  border-radius: 50%;
  background: var(--fc, #5f6368);
  flex-shrink: 0;
}

.gw-serp-item-meta-col {
  min-width: 0;
  flex: 1 1 auto;
}

.gw-serp-item-site {
  display: block;
  font-size: var(--fs-sm, 15px);
  color: #202124;
  line-height: 1.35;
  margin-bottom: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gw-serp-item-title {
  margin: 0 0 4px;
  font-size: var(--fs-lg, 18px);
  font-weight: 400;
  line-height: 1.35;
  max-width: var(--gw-serp-result-max);
}

.gw-serp-item-title a {
  color: #1a0dab;
  text-decoration: none;
}

.gw-serp-item-title a:hover {
  text-decoration: underline;
}

.gw-serp-item-title a:visited {
  color: #681da8;
}

.gw-serp-item-title mark {
  background: transparent;
  font-weight: 700;
}

.gw-serp-item-url {
  font-size: var(--fs-sm, 15px);
  color: #006621;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-bottom: 0;
}

.gw-serp-item-snippet {
  margin: 0;
  font-size: var(--fs-sm, 15px);
  color: #4d5156;
  line-height: 1.58;
  max-width: var(--gw-serp-result-max);
  overflow-wrap: break-word;
  word-break: normal;
}

.gw-serp-item-snippet mark {
  background: #fef08a;
  color: inherit;
  padding: 0 1px;
}

.gw-serp-item-extra {
  margin: 8px 0 0;
  font-size: var(--fs-sm, 15px);
  color: #9aa0a6;
}

.gw-serp-stats-ms {
  color: #9aa0a6;
}

.gw-serp-empty {
  padding: 40px 0;
  font-size: var(--fs-base, 16px);
  color: #70757a;
  line-height: 1.6;
}

.gw-serp-empty strong {
  color: #202124;
}

.gw-serp-thumb {
  flex-shrink: 0;
  margin-left: auto;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #dadce0;
}

.gw-serp-thumb img {
  display: block;
  width: 92px;
  height: 69px;
  object-fit: cover;
}

.gw-serp-ad {
  margin: 16px 0;
  display: grid;
  gap: 12px;
}

.gw-serp-ad--2col { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gw-serp-ad--3col { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.gw-serp-pager {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 28px;
  padding-top: 16px;
  border-top: 1px solid #ebebeb;
}

.gw-serp-page {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  min-height: 36px;
  padding: 0 10px;
  border-radius: 4px;
  font-size: var(--fs-sm, 15px);
  color: #1a73e8;
  text-decoration: none;
}

.gw-serp-page:hover { background: #f1f3f4; }
.gw-serp-page.is-on { background: #1a73e8; color: #fff; font-weight: 600; }
.gw-serp-page--more { font-weight: 600; }

.gw-serp-filter-panel--wide { min-width: 320px; max-width: 420px; }

.gw-serp-chips--portals {
  max-height: 160px;
  overflow-y: auto;
}

.gw-g-portal-list--scroll {
  max-height: 200px;
  overflow-y: auto;
}

/* SERP 하단 푸터 — Google 스타일 */
.gw-serp-root .gw-g-foot {
  margin-top: auto;
  background: #f2f2f2;
  border-top: 1px solid #dadce0;
}

.gw-serp-root .gw-g-foot-region {
  padding: 15px var(--gw-serp-pad-x);
  border-bottom: 1px solid #dadce0;
  font-size: var(--fs-sm, 15px);
  color: #70757a;
}

.gw-serp-root .gw-g-foot-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding: 15px var(--gw-serp-pad-x);
}

.gw-serp-root .gw-g-foot-nav a {
  font-size: var(--fs-sm, 15px);
  color: #70757a;
}

/* SERP — 내부 링크 미리보기 패널 */
.gw-serp-preview[hidden] {
  display: none !important;
}

.gw-serp-preview {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: flex;
  align-items: stretch;
  justify-content: center;
}

.gw-serp-preview-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(32, 33, 36, 0.45);
}

.gw-serp-preview-panel {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  width: min(960px, 100vw);
  max-height: 100vh;
  margin: 0;
  background: #fff;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.18);
}

.gw-serp-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 52px;
  padding: 8px 12px 8px 16px;
  border-bottom: 1px solid #dadce0;
  background: #f8f9fa;
}

.gw-serp-preview-title {
  margin: 0;
  min-width: 0;
  flex: 1 1 auto;
  font-size: var(--fs-md, 17px);
  font-weight: 600;
  color: #202124;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gw-serp-preview-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.gw-serp-preview-open {
  font-size: var(--fs-sm, 15px);
  font-weight: 600;
  color: #1a73e8;
  text-decoration: none;
  white-space: nowrap;
}

.gw-serp-preview-open:hover {
  text-decoration: underline;
}

.gw-serp-preview-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  font-size: var(--fs-2xl, 24px);
  line-height: 1;
  color: #5f6368;
  cursor: pointer;
}

.gw-serp-preview-close:hover {
  background: rgba(60, 64, 67, 0.08);
}

.gw-serp-preview-loading {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  transform: translate(-50%, -50%);
  font-size: var(--fs-sm, 15px);
  color: #70757a;
}

.gw-serp-preview-loading[hidden] {
  display: none !important;
}

.gw-serp-preview-frame {
  flex: 1 1 auto;
  width: 100%;
  min-height: 0;
  border: 0;
  background: #fff;
}

body.gw-serp-preview-open {
  overflow: hidden;
}

.gw-serp-link--preview {
  cursor: pointer;
}

@media (max-width: 779px) {
  .gw-serp-preview-panel {
    width: 100vw;
    max-height: 100dvh;
  }

  .gw-serp-preview-head {
    padding-left: 12px;
  }
}

.gw-serp-section-aside:empty,
.gw-serp-section-aside:not(:has(.gw-serp-aside-ad)) {
  display: none;
}

.gw-serp-section:not(:has(.gw-serp-aside-ad)) {
  grid-template-columns: minmax(0, var(--gw-serp-result-max));
}

/* 780px+ — 2열(결과+우측광고), 779px↓ — 1열 */
@media (min-width: 780px) {
  .gw-serp-section {
    grid-template-columns: minmax(0, var(--gw-serp-result-max)) minmax(180px, var(--gw-serp-aside-w));
  }

  .gw-serp-inline-ad {
    display: none;
  }
}

@media (max-width: 779px) {
  .gw-chrome--mobile {
    display: block;
  }

  .gw-chrome--desktop {
    display: none !important;
  }

  .gw-serp-shell {
    --gw-serp-pad-x: 16px;
    --gw-serp-content-inset: 16px;
    --gw-serp-logo-col: 44px;
    --gw-serp-result-max: 100%;
    --gw-serp-aside-w: 0px;
  }

  .gw-serp-branch-bar {
    padding-left: 16px;
    padding-right: 16px;
  }

  .gw-serp-tabs {
    padding: 0 12px;
    gap: 0 16px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .gw-serp-main {
    padding: 14px 16px 28px;
  }

  .gw-serp-section {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .gw-serp-section-aside {
    display: none;
  }

  .gw-serp-item-site {
    white-space: normal;
  }

  .gw-serp-item-url {
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .gw-serp-filter {
    margin-left: 0;
  }

  .gw-serp-thumb {
    display: none;
  }

  .gw-serp-ad--3col,
  .gw-serp-ad--2col {
    grid-template-columns: 1fr;
  }

  .gw-serp-root .gw-g-foot-region {
    padding: 12px 16px;
  }

  .gw-serp-root .gw-g-foot-row {
    flex-direction: column;
    align-items: flex-start;
    padding: 12px 16px 20px;
  }
}

/* 780–959px — 로고 유지 · 검색 축소 또는 돋보기 모달 */
@media (min-width: 780px) and (max-width: 959px) {
  .gw-serp-shell {
    --gw-serp-pad-x: 20px;
    --gw-serp-content-inset: 120px;
    --gw-serp-logo-col: 44px;
    --gw-serp-gap: 10px;
  }

  .gw-serp-header.gw-serp-header--compact .gw-serp-form {
    display: none;
  }

  .gw-serp-header.gw-serp-header--compact .gw-serp-search-compact {
    display: inline-flex;
    grid-column: 2;
  }

  .gw-g-top--serp .gw-g-account-name,
  .gw-g-top--serp .gw-g-lang-code,
  .gw-g-top--serp .gw-g-portal-btn-label {
    display: none;
  }

  .gw-g-top--serp .gw-g-icon-btn,
  .gw-g-top--serp .gw-g-account-btn {
    min-width: 36px;
    padding: 0 6px;
  }
}

/* ══ 이미지 검색 — search/image.php ══ */
body.gw-image-root {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  background: #fff;
}

.gw-img-main {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 16px 48px;
}

.gw-img-center {
  width: 100%;
  max-width: 584px;
  text-align: center;
}

.gw-img-eyebrow {
  margin: 0 0 20px;
  font-size: var(--fs-sm, 15px);
  color: #70757a;
}

.gw-img-form { width: 100%; }

.gw-img-bar { margin: 0 auto; }

.gw-img-hint {
  margin: 14px 0 0;
  font-size: var(--fs-sm, 15px);
  color: #70757a;
  line-height: 1.5;
}

.gw-img-soon {
  margin-top: 28px;
  padding: 16px;
  border-radius: 8px;
  background: #f8f9fa;
  font-size: var(--fs-sm, 15px);
  color: #5f6368;
}

