/* =========================================================
   common.css — 토큰 / 기본 초기화 / 헤더(GNB) / 푸터 / 공통 모달
   ========================================================= */

/* =========================================================
   WEB FONTS
   - Pretendard : 본문/UI 전체 (head.php link 태그)
   - Paperlogy  : 섹션 타이틀 + 히어로 강조 문구
   ========================================================= */
@font-face {
    font-family: 'Paperlogy';
    src: url('./Paperlogy-7Bold.woff2') format('woff2');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Paperlogy';
    src: url('./Paperlogy-6SemiBold.woff2') format('woff2');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

/* =========================================================
   TOKENS
   ========================================================= */
:root {
    --red: #E60012;
    --red-hover: #C2000F;
    --red-soft: #FDECEE;
    --ink-950: #0C0C0D;
    --ink-900: #151517;
    --ink-800: #1F1F22;
    --ink-700: #2E2E33;
    --ink-600: #45454B;
    --gray-500: #86868D;
    --gray-400: #A7A7AD;
    --gray-300: #CACACE;
    --gray-200: #E3E3E5;
    --gray-100: #F2F2F0;
    --gray-50: #F8F8F6;
    --text-strong: #17171A;
    --text-body: #4A4A50;
    --white: #fff;
    --cream: #FEF7E5;
    --section-py: 120px;
    --grid: 1300px;
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --gnb-h: 80px;
    --floating-h: 60px;
    --ease: cubic-bezier(.22,.61,.36,1);
    --ease-out: cubic-bezier(.16,1,.3,1);
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--gnb-h);
}

body {
    font-family: 'Pretendard',-apple-system,BlinkMacSystemFont,system-ui,sans-serif;
    letter-spacing: -0.025em;
    color: var(--text-strong);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
    word-break: keep-all;
    overflow-x: hidden;
}

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

a {
    color: inherit;
    text-decoration: none;
}

button {
    font: inherit;
    letter-spacing: inherit;
    border: 0;
    background: none;
    cursor: pointer;
    color: inherit;
}

ul {
    list-style: none;
}

.inner {
    width: var(--grid);
    max-width: calc(100% - 64px);
    margin: 0 auto;
}

.red {
    color: var(--red);
}

/* =========================================================
   GNB
   ========================================================= */
.gnb {
    position: fixed;
    inset: 0 0 auto;
    height: var(--gnb-h);
    z-index: 100;
    background: rgba(12,12,13,.82);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom: 1px solid rgba(255,255,255,.08);
    transition: background .4s,transform .4s var(--ease);
}

.gnb.scrolled {
    background: rgba(12,12,13,.94);
}

.gnb-inner {
    height: 100%;
    margin: 0 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.gnb .logo {
    display: block;
    cursor: pointer;
}

.gnb .logo svg {
    height: 24px;
    width: auto;
    display: block;
}

.gnb nav {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
}

.gnb nav ul {
    display: flex;
    gap: 18px;
}

.gnb nav a {
    position: relative;
    display: flex;
    align-items: center;
    height: var(--gnb-h);
    padding: 0 4px;
    font-size: 16px;
    font-weight: 500;
    color: var(--gray-300);
    transition: color .3s;
}

.gnb nav a::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    background: var(--red);
    transform: scaleX(0);
    transition: transform .35s var(--ease);
}

.gnb nav a:hover, .gnb nav a.active {
    color: #fff;
}

.gnb nav a:hover::after, .gnb nav a.active::after {
    transform: scaleX(1);
}

.gnb .util {
    display: flex;
    align-items: center;
    gap: 0px;
}

.sns {
    display: flex;
    gap: 8px;
}

.sns a {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: background .3s;
}

.sns a svg * {
    transition: stroke .3s;
}

.sns a:hover {
    background: rgba(255,255,255,.06);
}

.sns a:hover svg * {
    stroke: #fff;
}

.gnb .tel {
    margin-left: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    height: 44px;
    padding: 0 20px 0 16px;
    border-radius: 22px;
    background: var(--red);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    transition: background .3s, transform .3s var(--ease);
}

.gnb .tel:hover {
    background: var(--red-hover);
}

.gnb .tel svg {
    animation: ring 2.8s ease-in-out infinite;
}

@keyframes ring {
    0%, 80%, 100% {
        transform: rotate(0);
    }
    84% {
        transform: rotate(-14deg);
    }
    88% {
        transform: rotate(12deg);
    }
    92% {
        transform: rotate(-8deg);
    }
    96% {
        transform: rotate(4deg);
    }
}

.hamburger {
    display: none;
}

.mobile-menu {
    display: none;
}

/* =========================================================
   FOOTER / TOP
   ========================================================= */
.footer {
    background: var(--ink-950);
    color: #fff;
    padding: 64px 0 calc(64px + var(--floating-h));
}

.footer .top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer .top svg.logo {
    height: 28px;
    width: auto;
}

.footer hr {
    margin: 32px 0;
    border: 0;
    height: 1px;
    background: rgba(255,255,255,.1);
}

.footer .bot {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.footer .info p {
    font-size: 14px;
    color: var(--gray-500);
    line-height: 1.8;
}

.footer .ct {
    text-align: right;
}

.footer .ct span {
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-400);
}

.footer .ct a {
    display: block;
    font-size: 32px;
    font-weight: 700;
}

.to-top {
    position: fixed;
    right: 40px;
    bottom: calc(var(--floating-h) + 20px);
    z-index: 90;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--ink-800);
    border: 1px solid rgba(255,255,255,.15);
    color: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
    transition: opacity .4s,transform .4s var(--ease),background .3s;
}

.to-top.show {
    opacity: 1;
    transform: none;
    pointer-events: auto;
}

.to-top:hover {
    background: var(--red);
}

/* =========================================================
   하단 고정 문의 (PC #floating-container / 모바일 #floating-mo-container)
   ========================================================= */
#floating-container {
    max-width: 1300px;
    width: 100%;
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    bottom: 0;
    z-index: 80;
    padding: 3px 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid rgba(255,255,255,.1);
    border-bottom: 0;
    border-radius: 12px 12px 0 0;
    background: rgba(12,12,13,.92);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
}

#floating-container.is-hidden, #floating-mo-container.is-hidden {
    display: none;
}

.floating-form {
    max-width: 1240px;
    width: 100%;
    height: 54px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.floating-num {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #fff;
    font-family: 'Paperlogy','Pretendard',sans-serif;
    font-size: 24px;
    font-weight: 700;
    line-height: 125%;
    white-space: nowrap;
}

.floating-num p {
    display: flex;
    align-items: center;
}

.floating-num p span {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    margin-right: -1px;
    padding: 6px 10px;
    border-radius: 8px;
    background: var(--red);
    color: #fff;
    font-family: 'Pretendard',sans-serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 125%;
}

.input-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.input-wrap input[type="text"], .floating-mo-form .floating-mo-wrap input[type="text"] {
    width: 180px;
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255,255,255,.16);
    background: rgba(255,255,255,.08);
    color: #fff;
    font: inherit;
    font-size: 16px;
    line-height: 24px;
    outline: 0;
    transition: border-color .25s;
}

.input-wrap input[type="text"]:focus, .floating-mo-form .floating-mo-wrap input[type="text"]:focus {
    border-color: var(--red);
}

.input-wrap input[type="text"]::placeholder, .floating-mo-form .floating-mo-wrap input[type="text"]::placeholder {
    color: var(--gray-400);
}

.floating-form-wrap {
    display: flex;
    align-items: center;
    gap: 32px;
}

.floating-agree-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}

.floating-agree-wrap .checkbox-label {
    display: flex;
}

.floating-agree-wrap .round-checkbox {
    width: 25px;
    height: 25px;
    border: 1px solid rgba(255,255,255,.3);
    border-radius: 50%;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    background: transparent;
}

.floating-agree-wrap .round-checkbox:checked {
    border-color: var(--red);
    background: var(--red) url("../img/check.png") no-repeat center / 15px;
}

.floating-agree-wrap .agree {
    color: var(--gray-300);
    font-size: 14px;
    white-space: nowrap;
    cursor: pointer;
}

.floating-agree-wrap .agree-open {
    color: #fff;
    font-weight: 600;
    text-decoration: underline;
}

.f-btn {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 42px;
    padding: 0 40px;
    border: 0;
    border-radius: var(--radius-sm);
    background: var(--red);
    color: #fff;
    font: inherit;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: background .3s;
}

.f-btn:hover {
    background: var(--red-hover);
}

/* 모바일 고정 폼 (900px 이하에서 노출) */
#floating-mo-container {
    display: none;
    width: 100%;
    padding: 12px 20px;
    justify-content: center;
    align-items: center;
    gap: 8px;
    border-top: 1px solid rgba(255,255,255,.1);
    border-radius: 12px 12px 0 0;
    background: rgba(12,12,13,.94);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    position: fixed;
    left: 0;
    bottom: 0;
    z-index: 80;
}

.floating-mo-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.floating-logo {
    width: auto;
    height: 16px;
}

.floating-mo-form .floating-mo-div {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.floating-mo-form .floating-mo-wrap {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
}

.floating-mo-form .floating-mo-wrap input[type="text"], .floating-mo-form .floating-mo-wrap .f-btn {
    width: calc(25% - 3px);
    min-width: 0;
}

/* =========================================================
   개인정보처리방침 모달
   ========================================================= */
.modal-bg {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 150;
    background: #000;
    opacity: .5;
}

.agree-modal {
    display: none;
    position: fixed;
    top: 2.5vh;
    left: 50%;
    transform: translateX(-50%);
    z-index: 160;
    width: 1080px;
    max-width: calc(100% - 40px);
    height: 95vh;
    padding: 60px 48px 20px;
    border-radius: var(--radius-md);
    background: #fff;
    overflow: hidden;
}

.agree-close {
    position: absolute;
    top: 0;
    right: 0;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--ink-950);
    transition: background .3s;
}

.agree-close:hover {
    background: var(--red);
}

.agree-logo {
    height: 36px;
    margin: 0 auto 12px;
}

.agree-modal .title {
    text-align: center;
    font-size: 32px;
    font-weight: 700;
    line-height: 1.4;
}

.agree-modal .content {
    margin-top: 20px;
    height: calc(100% - 113px);
    padding-bottom: 20px;
    overflow-y: auto;
    font-size: 16px;
    line-height: 1.65;
    color: var(--text-body);
}

.mo-br {
    display: none;
}

.xs-br {
    display: none;
}

.xxs-br {
    display: none;
}

.xxxs-br {
    display: none;
}

/* =========================================================
   REDUCED MOTION
   ========================================================= */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation: none!important;
        transition: none!important;
    }
}

/* =========================================================
   RESPONSIVE — GNB
   - ~1440px : 메뉴 간격 축소
   - ~1360px : GNB SNS 아이콘 숨김 (모바일 메뉴/푸터에서 노출)
   - ~1100px : 햄버거 메뉴 전환
   ========================================================= */
@media (max-width: 1440px) {
    .gnb nav ul {
        gap: 12px;
    }
}

@media (max-width: 1360px) {
    .gnb .util .sns {
        display: none;
    }
}

@media(max-width: 1280px) {
    :root {
        --gnb-h: 65px;
        --section-py: 100px;
    }
    .gnb-inner {
        margin: 0 20px;
    }
    .gnb .logo svg {
        height: 22px;
    }
    .gnb .tel {
        font-size: 15px;
        letter-spacing: -0.375px;
        height: 38px;
        padding: 0 16px 0 12px;
    }
    .gnb nav a {
        font-size: 15px;
        letter-spacing: -0.375px;
    }
    .footer .top svg.logo {
        height: 24px;
    }
    .footer .ct a {
        font-size: 28px;
    }
    .inner {
        max-width: calc(100% - 40px);
    }
    /* ---- 하단 고정 문의 ---- */
    .floating-form-wrap {
        gap: 20px;
    }
    .floating-num {
        font-size: 20px;
    }
    .floating-num p span {
        font-size: 16px;
    }
    .input-wrap input[type="text"] {
        width: 150px;
    }
    .f-btn {
        font-size: 16px;
        padding: 0 32px;
    }
}

@media (max-width: 1100px) {
    /* ---- 하단 고정 문의 ---- */
    .input-wrap {
        gap: 4px;
    }
    .floating-form {
        gap: 12px;
    }
    .floating-form-wrap {
        gap: 12px;
    }
    .floating-num p {
        display: none;
    }
    .input-wrap input[type="text"] {
        width: 140px;
    }
    .f-btn {
        padding: 0 24px;
    }
}

@media (max-width: 1024px) {
    /* ---- GNB / mobile menu ---- */
    :root {
        --section-py: 88px;
        --gnb-h: 50px;
    }
    .gnb-inner {
        margin: 0 16px;
    }
    .gnb .logo svg {
        height: 20px;
    }
    .gnb nav, .gnb .util {
        display: none;
    }
    .hamburger {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 5px;
        width: 40px;
        height: 40px;
        flex: none;
    }
    .hamburger span {
        display: block;
        width: 22px;
        height: 2px;
        background: #fff;
        transition: transform .3s var(--ease),opacity .3s;
    }
    .hamburger.open span:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }
    .hamburger.open span:nth-child(2) {
        opacity: 0;
    }
    .hamburger.open span:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }
    .mobile-menu {
        display: block;
        position: fixed;
        inset: var(--gnb-h) 0 0 0;
        z-index: 99;
        background: rgba(12,12,13,.98);
        backdrop-filter: blur(12px);
        padding: 28px 24px;
        transform: translateX(100%);
        transition: transform .4s var(--ease);
        overflow-y: auto;
    }
    .mobile-menu.open {
        transform: translateX(0);
    }
    .mm-nav ul {
        display: flex;
        flex-direction: column;
        gap: 4px;
    }
    .mm-nav a {
        display: block;
        padding: 16px 4px;
        font-size: 16px;
        font-weight: 600;
        color: #fff;
        border-bottom: 1px solid rgba(255,255,255,.08);
    }
    .mm-sns {
        margin-top: 28px;
        gap: 12px;
    }
    .mm-sns a {
        width: 44px;
        height: 44px;
        border: 1px solid rgba(255,255,255,.15);
    }
    .mm-tel {
        width: fit-content;
        margin: 24px auto 0;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        height: 52px;
        padding: 0 20px;
        border-radius: 26px;
        background: var(--red);
        color: #fff;
        font-size: 17px;
        font-weight: 700;
    }
    html.menu-open {
        overflow: hidden;
    }
    /* ---- 하단 고정 문의 ---- */
    .input-wrap input[type="text"] {
        width: 128px;
    }
}

@media (max-width: 900px) {
    /* ---- 하단 고정 문의 : PC 바 → 모바일 폼 ---- */
    :root {
        --floating-h: 100px;
    }
    #floating-container {
        display: none;
    }
    #floating-mo-container {
        display: flex;
    }
    .f-btn {
        padding: 0;
    }
}

@media (max-width: 768px) {
    :root {
        --section-py: 72px;
    }
    .footer {
        padding: 56px 0 calc(56px + var(--floating-h));
    }
    .footer .bot {
        flex-direction: column;
        align-items: flex-start;
        gap: 24px;
    }
    .footer .ct {
        text-align: left;
    }
    .footer .ct a {
        font-size: 28px;
    }
    .to-top {
        right: 24px;
        bottom: calc(var(--floating-h) + 16px);
        width: 56px;
        height: 56px;
    }
}

/* =========================================================
   MOBILE (375px 기준, ~640px 이하)
   ========================================================= */
@media (max-width: 640px) {
    :root {
        --section-py: 64px;
        --gnb-h: 60px;
    }
    .inner {
        width: 100%;
        max-width: calc(100% - 40px);
    }
    /* ---- footer ---- */
    .footer {
        padding: 48px 0 calc(48px + var(--floating-h));
    }
    .footer .top {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    .footer .bot {
        flex-direction: column;
        align-items: flex-start;
        gap: 24px;
    }
    .footer .ct {
        text-align: left;
    }
    .footer .ct a {
        font-size: 24px;
    }
    .to-top {
        right: 16px;
        bottom: calc(var(--floating-h) + 12px);
        width: 52px;
        height: 52px;
    }
    /* ---- 개인정보처리방침 모달 ---- */
    .agree-modal {
        padding: 56px 20px 16px;
    }
    .agree-modal .title {
        font-size: 24px;
    }
    .agree-logo {
        height: 30px;
        margin-bottom: 10px;
    }
    .agree-modal .content {
        height: calc(100% - 94px);
        font-size: 14px;
    }
    .mo-br {
        display: block;
    }
}

@media (max-width: 480px) {
    /* ---- 하단 고정 문의 ---- */
    #floating-mo-container {
        padding: 12px 10px;
    }
    .floating-mo-form .floating-mo-wrap input[type="text"] {
        padding: 8px 6px;
        font-size: 14px;
    }
    .f-btn {
        height: 42px;
        font-size: 15px;
    }
    .xs-br {
        display: block;
    }
}

@media(max-width: 400px) {
    .xxs-br {
        display: block;
    }
    .xxs-no-br {
        display: none;
    }
}

@media(max-width: 370px) {
    .xxxs-br {
        display: block;
    }
}
