/* ============================================================
   Growthify Law — Main Stylesheet
   의정부 형사사건전문변호사 전재욱 | 법률사무소 부광
   ============================================================ */

/* ── CSS Variables ── */
:root {
    --gl-navy:        #1B2A4A;
    --gl-navy-light:  #2A3F6B;
    --gl-navy-dark:   #0F1A30;
    --gl-gold:        #C4960C;
    --gl-gold-light:  #F5E6B8;
    --gl-gold-muted:  #9D856D;
    --gl-dark:        #111111;
    --gl-dark-soft:   #1A1A1A;
    --gl-light:       #F5F3EF;
    --gl-light-alt:   #FAF9F7;
    --gl-white:       #FFFFFF;
    --gl-text:        #333333;
    --gl-text-light:  #888888;
    --gl-text-muted:  #AAAAAA;
    --gl-border:      #E5E7EB;
    --gl-shadow:      0 4px 20px rgba(0,0,0,0.08);
    --gl-shadow-lg:   0 8px 40px rgba(0,0,0,0.12);
    --gl-radius:      8px;
    --gl-radius-lg:   16px;
    --gl-transition:  0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --gl-header-h:    72px;
    --gl-font:        'Pretendard Variable', 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
    --gl-font-serif:  'Nanum Myeongjo', Georgia, serif;
    --gl-container:   1200px;
}

/* ── Reset & Base ── */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--gl-font);
    font-size: 16px;
    line-height: 1.6;
    color: var(--gl-text);
    background: var(--gl-white);
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--gl-transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul, ol {
    list-style: none;
}

/* ── Container ── */
.gl-container {
    max-width: var(--gl-container);
    margin: 0 auto;
    padding: 0 24px;
}

/* ── Header ── */
.gl-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--gl-header-h);
    z-index: 1000;
    transition: background var(--gl-transition), box-shadow var(--gl-transition);
}

.gl-header.is-scrolled {
    background: rgba(17, 17, 17, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

/* 메인 페이지에서는 투명, 내부 페이지에서는 불투명 */
body:not(.home) .gl-header {
    background: var(--gl-dark);
}

.gl-header-inner {
    max-width: var(--gl-container);
    margin: 0 auto;
    padding: 0 24px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* 로고 */
.gl-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 1001;
}

.gl-logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}

.gl-logo-firm {
    font-size: 11px;
    color: var(--gl-gold);
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.gl-logo-name {
    font-size: 18px;
    color: var(--gl-white);
    font-weight: 700;
}

/* 데스크톱 네비게이션 */
.gl-nav-desktop {
    display: flex;
    align-items: center;
}

.gl-nav-list {
    display: flex;
    gap: 36px;
    align-items: center;
}

.gl-nav-list > li {
    position: relative;
}

.gl-nav-list > li > a {
    color: rgba(255, 255, 255, 0.8);
    font-size: 15px;
    font-weight: 500;
    padding: 8px 0;
    transition: color var(--gl-transition);
    position: relative;
}

.gl-nav-list > li > a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gl-gold);
    transition: width var(--gl-transition);
}

.gl-nav-list > li > a:hover,
.gl-nav-list > li > a.is-active {
    color: var(--gl-white);
}

.gl-nav-list > li > a:hover::after,
.gl-nav-list > li > a.is-active::after {
    width: 100%;
}

/* 드롭다운 */
.gl-nav-dropdown {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: var(--gl-dark);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: var(--gl-radius);
    padding: 12px 0;
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    transition: all var(--gl-transition);
    box-shadow: var(--gl-shadow-lg);
}

.gl-nav-list > li:hover .gl-nav-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.gl-nav-dropdown li a {
    display: block;
    padding: 8px 20px;
    color: rgba(255,255,255,0.7);
    font-size: 14px;
    transition: all var(--gl-transition);
}

.gl-nav-dropdown li a:hover {
    color: var(--gl-gold);
    background: rgba(255,255,255,0.05);
}

/* 헤더 CTA */
.gl-header-cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--gl-gold);
    color: var(--gl-dark);
    padding: 8px 20px;
    border-radius: 100px;
    font-size: 14px;
    font-weight: 700;
    transition: all var(--gl-transition);
}

.gl-header-cta:hover {
    background: var(--gl-white);
    color: var(--gl-dark);
    transform: translateY(-1px);
}

/* 햄버거 */
.gl-hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.gl-hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--gl-white);
    transition: all var(--gl-transition);
}

.gl-hamburger.is-active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.gl-hamburger.is-active span:nth-child(2) {
    opacity: 0;
}

.gl-hamburger.is-active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* 모바일 네비게이션 */
.gl-mobile-nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background: var(--gl-dark);
    z-index: 999;
    transition: right var(--gl-transition);
    padding: calc(var(--gl-header-h) + 20px) 24px 24px;
    overflow-y: auto;
}

.gl-mobile-nav.is-open {
    right: 0;
}

.gl-mobile-nav-list > li > a,
.gl-mobile-nav-group-title {
    display: block;
    padding: 14px 0;
    color: var(--gl-white);
    font-size: 18px;
    font-weight: 600;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.gl-mobile-nav-group-title {
    color: var(--gl-gold);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding-bottom: 8px;
    margin-top: 16px;
}

.gl-mobile-nav-group ul li a {
    display: block;
    padding: 10px 0 10px 16px;
    color: rgba(255,255,255,0.7);
    font-size: 15px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.gl-mobile-cta {
    display: block;
    margin-top: 32px;
    background: var(--gl-gold);
    color: var(--gl-dark);
    text-align: center;
    padding: 16px;
    border-radius: var(--gl-radius);
    font-size: 18px;
    font-weight: 700;
}

/* 플로팅 전화 버튼 */
.gl-floating-phone {
    display: none;
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 56px;
    height: 56px;
    background: var(--gl-gold);
    color: var(--gl-dark);
    border-radius: 50%;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(196, 150, 12, 0.4);
    z-index: 990;
    transition: transform var(--gl-transition);
}

.gl-floating-phone:hover {
    transform: scale(1.1);
}

/* ── 섹션 공통 ── */
.gl-section {
    padding: 100px 0;
    position: relative;
}

.gl-section-dark {
    background: var(--gl-dark);
    color: var(--gl-white);
}

.gl-section-light {
    background: var(--gl-light);
}

.gl-section-navy {
    background: var(--gl-navy);
    color: var(--gl-white);
}

.gl-section-header {
    text-align: center;
    margin-bottom: 60px;
}

.gl-section-label {
    font-size: 13px;
    color: var(--gl-gold);
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.gl-section-title {
    font-size: 36px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 16px;
}

.gl-section-dark .gl-section-title {
    color: var(--gl-white);
}

.gl-section-desc {
    font-size: 16px;
    color: var(--gl-text-light);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

.gl-section-dark .gl-section-desc {
    color: rgba(255,255,255,0.6);
}

/* ── 히어로 섹션 ── */
.gl-hero {
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background: var(--gl-dark);
}

.gl-hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0.3;
}

.gl-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(17,17,17,0.4) 0%, rgba(17,17,17,0.8) 100%);
}

.gl-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 0 24px;
}

.gl-hero-label {
    font-size: 14px;
    color: var(--gl-gold);
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(20px);
}

.gl-hero-title {
    font-size: 56px;
    font-weight: 800;
    color: var(--gl-white);
    line-height: 1.2;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(30px);
}

.gl-hero-title span {
    color: var(--gl-gold);
}

.gl-hero-subtitle {
    font-size: 20px;
    color: rgba(255,255,255,0.7);
    margin-bottom: 40px;
    opacity: 0;
    transform: translateY(20px);
}

.gl-hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    opacity: 0;
    transform: translateY(20px);
}

.gl-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    border-radius: 100px;
    font-size: 16px;
    font-weight: 700;
    transition: all var(--gl-transition);
    border: none;
    cursor: pointer;
}

.gl-btn-gold {
    background: var(--gl-gold);
    color: var(--gl-dark);
}

.gl-btn-gold:hover {
    background: var(--gl-white);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(196, 150, 12, 0.3);
}

.gl-btn-outline {
    background: transparent;
    color: var(--gl-white);
    border: 1px solid rgba(255,255,255,0.3);
}

.gl-btn-outline:hover {
    border-color: var(--gl-gold);
    color: var(--gl-gold);
}

.gl-hero-scroll {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,0.5);
    font-size: 13px;
    text-align: center;
    animation: gl-bounce 2s infinite;
}

.gl-hero-scroll svg {
    display: block;
    margin: 8px auto 0;
}

@keyframes gl-bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(10px); }
}

/* ── 카운터 섹션 ── */
.gl-counters {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    text-align: center;
}

.gl-counter-item {
    padding: 32px 16px;
}

.gl-counter-number {
    font-size: 56px;
    font-weight: 800;
    color: var(--gl-gold);
    line-height: 1;
    margin-bottom: 8px;
    font-variant-numeric: tabular-nums;
}

.gl-counter-suffix {
    font-size: 24px;
    font-weight: 400;
}

.gl-counter-label {
    font-size: 15px;
    color: rgba(255,255,255,0.6);
    font-weight: 500;
}

/* ── 전문 분야 카드 그리드 ── */
.gl-practice-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.gl-practice-card {
    position: relative;
    border-radius: var(--gl-radius-lg);
    padding: 32px 24px 28px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    transition: all var(--gl-transition);
    display: flex;
    flex-direction: column;
}

.gl-practice-card:hover {
    background: rgba(255,255,255,0.08);
    border-color: var(--gl-gold);
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(196, 150, 12, 0.1);
}

.gl-practice-card-icon {
    width: 48px;
    height: 48px;
    margin-bottom: 20px;
    color: var(--gl-gold);
}

.gl-practice-card-icon svg {
    width: 100%;
    height: 100%;
}

.gl-practice-card-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--gl-white);
    margin-bottom: 10px;
}

.gl-practice-card-desc {
    font-size: 14px;
    color: rgba(255,255,255,0.5);
    line-height: 1.6;
    flex: 1;
    margin-bottom: 16px;
}

.gl-practice-card-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--gl-gold);
    opacity: 0;
    transform: translateX(-8px);
    transition: all var(--gl-transition);
}

.gl-practice-card:hover .gl-practice-card-link {
    opacity: 1;
    transform: translateX(0);
}

/* ── 변호사 프로필 ── */
.gl-attorney-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.gl-attorney-photo {
    position: relative;
    border-radius: var(--gl-radius-lg);
    overflow: hidden;
    aspect-ratio: 4/5;
}

.gl-attorney-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gl-attorney-photo::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 30%;
    background: linear-gradient(transparent, rgba(0,0,0,0.3));
}

.gl-attorney-info {
    padding: 20px 0;
}

.gl-attorney-name {
    font-size: 42px;
    font-weight: 800;
    color: var(--gl-white);
    margin-bottom: 8px;
}

.gl-attorney-title {
    font-size: 16px;
    color: var(--gl-gold);
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 24px;
}

.gl-attorney-bio {
    font-size: 16px;
    color: rgba(255,255,255,0.7);
    line-height: 1.8;
    margin-bottom: 32px;
}

.gl-attorney-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 32px;
}

.gl-attorney-stat {
    padding: 16px;
    background: rgba(255,255,255,0.05);
    border-radius: var(--gl-radius);
    border-left: 3px solid var(--gl-gold);
}

.gl-attorney-stat-value {
    font-size: 28px;
    font-weight: 800;
    color: var(--gl-gold);
}

.gl-attorney-stat-label {
    font-size: 13px;
    color: rgba(255,255,255,0.5);
    margin-top: 4px;
}

/* ── 최근 포스트 캐러셀 ── */
.gl-posts-carousel .swiper-slide {
    height: auto;
}

.gl-post-card {
    background: var(--gl-white);
    border-radius: var(--gl-radius-lg);
    border: 1px solid var(--gl-border);
    transition: all var(--gl-transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.gl-post-card:hover {
    transform: translateY(-4px);
    border-color: var(--gl-gold);
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
}

.gl-post-card-body {
    padding: 28px 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.gl-post-card-category {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    color: var(--gl-gold);
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--gl-border);
    align-self: flex-start;
}

.gl-post-card-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--gl-navy);
    line-height: 1.45;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gl-post-card:hover .gl-post-card-title {
    color: var(--gl-gold);
}

.gl-post-card-excerpt {
    font-size: 14px;
    color: var(--gl-text-light);
    line-height: 1.65;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gl-post-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid var(--gl-border);
    font-size: 13px;
    color: var(--gl-text-muted);
}

.gl-post-card-readmore {
    color: var(--gl-gold);
    font-weight: 600;
    transition: color var(--gl-transition);
}

.gl-post-card:hover .gl-post-card-readmore {
    color: var(--gl-navy);
}

/* ── YouTube 영상 그리드 ── */
.gl-video-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.gl-video-item {
    position: relative;
    aspect-ratio: 16/9;
    border-radius: var(--gl-radius-lg);
    overflow: hidden;
    cursor: pointer;
    background: var(--gl-dark);
}

.gl-video-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity var(--gl-transition);
}

.gl-video-item:hover img {
    opacity: 0.7;
}

.gl-video-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--gl-transition);
}

.gl-video-item:hover .gl-video-play {
    background: var(--gl-gold);
    transform: translate(-50%, -50%) scale(1.1);
}

/* 비디오 모달 */
.gl-video-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.9);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.gl-video-modal.is-open {
    display: flex;
}

.gl-video-modal-inner {
    width: 100%;
    max-width: 900px;
    aspect-ratio: 16/9;
    position: relative;
}

.gl-video-modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    color: var(--gl-white);
    font-size: 32px;
    background: none;
    border: none;
    cursor: pointer;
}

.gl-video-modal iframe {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: var(--gl-radius);
}

/* ── 상담 CTA 섹션 ── */
.gl-consultation {
    text-align: center;
}

.gl-consultation-phone {
    font-size: 48px;
    font-weight: 800;
    color: var(--gl-gold);
    margin-bottom: 16px;
    letter-spacing: 2px;
}

.gl-consultation-desc {
    font-size: 17px;
    color: rgba(255,255,255,0.7);
    line-height: 1.7;
    margin-bottom: 40px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

/* ── 푸터 ── */
.gl-footer {
    background: var(--gl-dark);
    color: rgba(255,255,255,0.6);
    padding: 60px 0 0;
}

.gl-footer-inner {
    max-width: var(--gl-container);
    margin: 0 auto;
    padding: 0 24px;
}

.gl-footer-top {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 60px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.gl-footer-logo {
    font-size: 20px;
    font-weight: 700;
    color: var(--gl-white);
    margin-bottom: 6px;
}

.gl-footer-attorney {
    font-size: 14px;
    color: var(--gl-gold);
    margin-bottom: 20px;
}

.gl-footer-contact p {
    font-size: 14px;
    line-height: 1.8;
}

.gl-footer-contact strong {
    color: rgba(255,255,255,0.8);
    display: inline-block;
    width: 60px;
}

.gl-footer-links {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.gl-footer-link-group h4 {
    color: var(--gl-white);
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 16px;
}

.gl-footer-link-group ul li {
    margin-bottom: 8px;
}

.gl-footer-link-group ul li a {
    font-size: 14px;
    color: rgba(255,255,255,0.5);
    transition: color var(--gl-transition);
}

.gl-footer-link-group ul li a:hover {
    color: var(--gl-gold);
}

.gl-footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 0;
    font-size: 13px;
}

.gl-footer-legal {
    display: flex;
    gap: 8px;
}

.gl-footer-legal a {
    color: rgba(255,255,255,0.4);
    transition: color var(--gl-transition);
}

.gl-footer-legal a:hover {
    color: var(--gl-gold);
}

.gl-sep {
    color: rgba(255,255,255,0.2);
}

/* ── 스크롤 애니메이션 공통 ── */
.gl-fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.gl-fade-up.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.gl-fade-left {
    opacity: 0;
    transform: translateX(-30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.gl-fade-left.is-visible {
    opacity: 1;
    transform: translateX(0);
}

.gl-fade-right {
    opacity: 0;
    transform: translateX(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.gl-fade-right.is-visible {
    opacity: 1;
    transform: translateX(0);
}

/* ── 유틸리티 ── */
.gl-text-gold { color: var(--gl-gold); }
.gl-text-white { color: var(--gl-white); }
.gl-text-center { text-align: center; }
.gl-mt-0 { margin-top: 0; }
.gl-mb-0 { margin-bottom: 0; }
