/* ==========================================================================
   KSAP 워드프레스 랜딩 페이지 전용 CSS
   - 테마 충돌을 방지하기 위해 모든 클래스명에 'ksap-wp-' 접두사를 붙였습니다.
   ========================================================================== */

.ksap-wp-hero-section {
    padding: 160px 20px 100px;
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    animation: ksapWpFadeInDown 0.8s ease forwards;
    z-index: 10;
    font-family: 'Pretendard Variable', Pretendard, sans-serif;
}

@keyframes ksapWpFadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ksap-wp-hero-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    z-index: -1;
    opacity: 0.6;
    animation: ksapWpFloatGlow 8s infinite alternate ease-in-out;
}

.ksap-wp-shape-1 {
    top: -10%;
    left: 10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(255, 59, 92, 0.4) 0%, transparent 70%);
}

.ksap-wp-shape-2 {
    bottom: 10%;
    right: 5%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255, 140, 66, 0.25) 0%, transparent 70%);
    animation-delay: -4s;
}

@keyframes ksapWpFloatGlow {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(30px, -30px) scale(1.1);
    }
}

.ksap-wp-hero-particles {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -1;
    pointer-events: none;
}

.ksap-wp-particle {
    position: absolute;
    background: white;
    border-radius: 50%;
    opacity: 0.3;
}

.ksap-wp-p-1 {
    width: 6px;
    height: 6px;
    top: 20%;
    left: 15%;
    animation: ksapWpParticleFloat 4s infinite alternate;
}

.ksap-wp-p-2 {
    width: 4px;
    height: 4px;
    top: 40%;
    right: 20%;
    animation: ksapWpParticleFloat 5s infinite alternate-reverse;
}

.ksap-wp-p-3 {
    width: 8px;
    height: 8px;
    bottom: 30%;
    left: 25%;
    animation: ksapWpParticleFloat 6s infinite alternate;
}

@keyframes ksapWpParticleFloat {
    0% {
        transform: translateY(0);
        opacity: 0.2;
    }

    100% {
        transform: translateY(-20px);
        opacity: 0.8;
    }
}

.ksap-wp-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 59, 92, 0.15);
    border: 1px solid rgba(255, 59, 92, 0.3);
    padding: 8px 20px;
    border-radius: 30px;
    margin: 0 0 16px 0 !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(255, 59, 92, 0.2);
    animation: ksapWpPulseBadge 2.5s infinite;
}

@keyframes ksapWpPulseBadge {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 59, 92, 0.4);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(255, 59, 92, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(255, 59, 92, 0);
    }
}

.ksap-wp-badge-text {
    color: #ff5e7a;
    font-size: 0.9rem;
    font-weight: 800;
    letter-spacing: 1.5px;
}

.ksap-wp-hero-layout {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 60px;
    text-align: right;
}

.ksap-wp-hero-text-area {
    flex: 1;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.ksap-wp-hero-title {
    margin: 0 0 24px 0 !important;
    padding: 0 !important;
    line-height: 1.3 !important;
    letter-spacing: -1px;
    word-break: keep-all;
    background: transparent !important;
}

.ksap-wp-title-sub {
    font-size: 1.6rem;
    font-weight: 600;
    color: #9aa0a6;
    display: inline-block;
    margin: 0 0 8px 0 !important;
    padding: 0 !important;
}

.ksap-wp-title-main {
    font-size: 3.2rem;
    font-weight: 900;
    text-shadow: 0 10px 30px rgba(255, 59, 92, 0.4);
}

.ksap-wp-text-gradient {
    background: linear-gradient(135deg, #ff3b5c 0%, #ff8c42 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.ksap-wp-hero-desc {
    font-size: 1.15rem;
    color: #b0b5be;
    line-height: 1.8;
    margin-bottom: 40px;
    word-break: keep-all;
}

.ksap-wp-hero-desc strong {
    color: #ffd166;
    font-weight: 800;
    background: rgba(255, 209, 102, 0.15);
    padding: 2px 8px;
    border-radius: 6px;
}

.ksap-wp-hero-desc span {
    color: white;
    font-weight: 700;
}

.ksap-wp-hero-highlights {
    display: flex;
    flex-direction: column;
    gap: 16px;
    background: rgba(26, 28, 35, 0.6);
    backdrop-filter: blur(20px);
    padding: 24px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-align: right;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
    transition: all 0.3s;
}

.ksap-wp-hero-highlights:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 20px 40px rgba(255, 59, 92, 0.15);
}

.ksap-wp-highlight-item {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-direction: row-reverse;
    gap: 16px;
    padding: 8px 0;
}

.ksap-wp-icon-bulb {
    font-size: 1.8rem;
    background: rgba(255, 255, 255, 0.05);
    width: 50px;
    height: 50px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    transition: all 0.3s;
}

.ksap-wp-highlight-item:hover .ksap-wp-icon-bulb {
    transform: scale(1.1) rotate(5deg);
    border-color: rgba(255, 59, 92, 0.4);
    box-shadow: 0 15px 30px rgba(255, 59, 92, 0.3);
}

.ksap-wp-highlight-text strong {
    display: block;
    font-size: 1.15rem;
    color: white;
    margin-bottom: 6px;
    font-weight: 700;
}

.ksap-wp-highlight-text p {
    font-size: 0.95rem;
    color: #9aa0a6;
    line-height: 1.4;
    margin: 0;
}

.ksap-wp-hero-image-area {
    flex: 1;
    display: flex;
    justify-content: center;
    position: relative;
    max-width: 460px;
    margin: 0 auto;
}

.ksap-wp-book-cover-wrapper {
    position: relative;
    width: 100%;
    transform-style: preserve-3d;
    transform: perspective(1000px) rotateY(-15deg) rotateX(5deg);
    transition: transform 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
    animation: ksapWpFloatCover 6s ease-in-out infinite;
    z-index: 2;
}

.ksap-wp-book-cover-wrapper:hover {
    transform: perspective(1000px) rotateY(-8deg) rotateX(2deg) translateY(-10px) scale(1.02);
}

@keyframes ksapWpFloatCover {

    0%,
    100% {
        transform: perspective(1000px) rotateY(-15deg) rotateX(5deg) translateY(0);
    }

    50% {
        transform: perspective(1000px) rotateY(-10deg) rotateX(2deg) translateY(-15px);
    }
}

.ksap-wp-book-cover-img {
    width: 100%;
    border-radius: 4px 16px 16px 4px;
    box-shadow: inset 4px 0 10px rgba(255, 255, 255, 0.2);
    display: block;
    position: relative;
    z-index: 3;
    transform: translateZ(20px);
}

/* 3D Book Thickness */
.ksap-wp-book-edge {
    position: absolute;
    top: 2%;
    right: -48px;
    width: 50px;
    height: 96%;
    background: linear-gradient(to right, #ccc 0%, #eee 15%, #fff 50%, #e0e0e0 85%, #bbb 100%);
    border-radius: 0 10px 10px 0;
    transform: translateZ(5px);
    z-index: 2;
    background-image: repeating-linear-gradient(to bottom, transparent, transparent 2px, rgba(0, 0, 0, 0.03) 2px, rgba(0, 0, 0, 0.03) 3px), linear-gradient(to right, #ccc 0%, #eee 15%, #fff 50%, #e0e0e0 85%, #bbb 100%);
    box-shadow: inset 1px 0 3px rgba(0, 0, 0, 0.4), 20px 20px 40px rgba(0, 0, 0, 0.6);
}

/* 3D Book Back Cover to darken the gap */
.ksap-wp-book-cover-wrapper::after {
    content: '';
    position: absolute;
    top: 2%;
    right: -50px;
    width: 60px;
    height: 96%;
    background: #111;
    border-radius: 6px;
    transform: translateZ(-2px);
    z-index: 1;
    box-shadow: -15px 25px 40px rgba(0, 0, 0, 0.8);
}

.ksap-wp-book-glow {
    position: absolute;
    top: 10%;
    left: 10%;
    width: 80%;
    height: 80%;
    background: #ff3b5c;
    filter: blur(60px);
    opacity: 0.5;
    z-index: 1;
    animation: ksapWpPulseGlow 4s infinite alternate;
}

@keyframes ksapWpPulseGlow {
    0% {
        opacity: 0.4;
        transform: scale(0.9);
    }

    100% {
        opacity: 0.7;
        transform: scale(1.1);
    }
}

.ksap-wp-floating-badge-1,
.ksap-wp-floating-badge-2,
.ksap-wp-floating-badge-3,
.ksap-wp-floating-badge-4 {
    position: absolute;
    background: rgba(26, 28, 35, 0.85);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 10px 18px;
    border-radius: 12px;
    font-weight: 800;
    color: white;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4);
    z-index: 10;
    pointer-events: none;
    transform: translateZ(30px);
}

.ksap-wp-floating-badge-1 {
    top: -5%;
    left: -2%;
    transform: translateZ(40px) rotate(-8deg);
    animation: ksapWpBadgeFloat1 5s infinite ease-in-out;
}

.ksap-wp-floating-badge-2 {
    bottom: 25%;
    right: -15%;
    background: linear-gradient(135deg, #ff3b5c 0%, #ff8c42 100%);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateZ(40px) rotate(6deg);
    animation: ksapWpBadgeFloat2 6s infinite ease-in-out reverse;
}

.ksap-wp-floating-badge-3 {
    top: -5%;
    right: 5%;
    background: #4ade80;
    color: #0d1017;
    border-color: rgba(0, 0, 0, 0.1);
    transform: translateZ(35px) rotate(4deg);
    animation: ksapWpBadgeFloat1 6s infinite ease-in-out 1s;
}

.ksap-wp-floating-badge-4 {
    bottom: 22%;
    left: 4%;
    background: rgba(80, 110, 255, 0.9);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateZ(50px) rotate(-5deg);
    animation: ksapWpBadgeFloat2 5.5s infinite ease-in-out 0.5s;
}

@keyframes ksapWpBadgeFloat1 {

    0%,
    100% {
        transform: translateZ(40px) rotate(-5deg) translateY(0);
    }

    50% {
        transform: translateZ(40px) rotate(-2deg) translateY(-10px);
    }
}

@keyframes ksapWpBadgeFloat2 {

    0%,
    100% {
        transform: translateZ(40px) rotate(5deg) translateY(0);
    }

    50% {
        transform: translateZ(40px) rotate(8deg) translateY(-8px);
    }
}

/* Detail Section */
.ksap-wp-detail-section {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px 40px;
}

.ksap-wp-img-wrapper {
    position: relative;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
}

.ksap-wp-detail-image {
    width: 100%;
    display: block;
}

/* Floating Bar */
.ksap-wp-floating-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(20, 22, 28, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 16px 0;
    z-index: 999;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.6);
    transform: translateY(100%);
    animation: ksapWpSlideUp 0.6s 0.3s forwards cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes ksapWpSlideUp {
    to {
        transform: translateY(0);
    }
}

.ksap-wp-floating-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.ksap-wp-timer-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
}

.ksap-wp-timer-label {
    font-size: 0.95rem;
    font-weight: 600;
    color: #ff5e7a;
    background: rgba(255, 59, 92, 0.1);
    padding: 4px 10px;
    border-radius: 6px;
}

.ksap-wp-timer {
    display: flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
    font-weight: 800;
    font-size: 1.35rem;
    text-shadow: 0 2px 10px rgba(255, 59, 92, 0.4);
}

.ksap-wp-time-block {
    background: #1a1c23;
    padding: 8px 12px;
    border-radius: 8px;
    min-width: 50px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.05);
}

.ksap-wp-time-sep {
    color: #9aa0a6;
    font-size: 0.92rem;
    font-weight: 700;
    white-space: nowrap;
}

.ksap-wp-floating-actions {
    display: flex;
    gap: 12px;
    flex: 1;
    justify-content: flex-end;
}

.ksap-wp-btn {
    padding: 16px 32px;
    border-radius: 12px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    letter-spacing: -0.3px;
}

.ksap-wp-btn-primary {
    background: linear-gradient(135deg, #ff3b5c 0%, #ff8c42 100%);
    color: white;
    box-shadow: 0 10px 25px rgba(255, 59, 92, 0.4);
    flex: 1;
    max-width: 260px;
    position: relative;
    overflow: hidden;
}

.ksap-wp-btn-primary::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transform: skewX(-20deg);
    animation: ksapWpShine 3s infinite;
}

@keyframes ksapWpShine {
    0% {
        left: -100%;
    }

    20% {
        left: 200%;
    }

    100% {
        left: 200%;
    }
}

.ksap-wp-btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(255, 59, 92, 0.5);
}

.ksap-wp-btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.ksap-wp-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
}

/* Modal */
.ksap-wp-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.ksap-wp-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.ksap-wp-modal-content {
    background: #0d0e12;
    padding: 40px;
    border-radius: 24px;
    width: 90%;
    max-width: 420px;
    text-align: center;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.8), inset 0 2px 20px rgba(255, 255, 255, 0.05);
    transform: translateY(30px) scale(0.95);
    transition: all 0.3s;
}

.ksap-wp-modal-overlay.active .ksap-wp-modal-content {
    transform: translateY(0) scale(1);
}

.ksap-wp-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #9aa0a6;
    font-size: 1.5rem;
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
}

.ksap-wp-modal-close:hover {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    transform: rotate(90deg);
}

.ksap-wp-modal-icon {
    font-size: 4rem;
    margin-bottom: 8px;
    filter: drop-shadow(0 10px 20px rgba(255, 59, 92, 0.3));
    animation: ksapWpBounce 2s infinite ease-in-out;
}

@keyframes ksapWpBounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.ksap-wp-modal-title {
    font-size: 1.7rem;
    font-weight: 800;
    margin-bottom: 12px;
    letter-spacing: -0.5px;
    color: white;
}

.ksap-wp-modal-desc {
    color: #9aa0a6;
    margin-bottom: 28px;
    font-size: 1rem;
}

.ksap-wp-coupon-box {
    background: rgba(0, 0, 0, 0.4);
    border: 1px dashed rgba(255, 59, 92, 0.6);
    padding: 16px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}

.ksap-wp-coupon-code {
    font-size: 1.4rem;
    font-weight: 800;
    color: #ff3b5c;
    letter-spacing: 2px;
}

.ksap-wp-btn-copy {
    background: linear-gradient(135deg, #ff3b5c 0%, #ff8c42 100%);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(255, 59, 92, 0.3);
}

.ksap-wp-btn-copy:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 59, 92, 0.4);
}

.ksap-wp-copy-success-msg {
    color: #4ade80;
    font-size: 0.9rem;
    font-weight: 600;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s;
}

.ksap-wp-copy-success-msg.show {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 1024px) {
    .ksap-wp-hero-layout {
        flex-direction: column;
        text-align: center;
        gap: 50px;
    }

    .ksap-wp-hero-text-area {
        max-width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .ksap-wp-hero-highlights {
        align-self: stretch;
        text-align: center;
    }

    .ksap-wp-hero-image-area {
        max-width: 400px;
        width: 100%;
    }

    .ksap-wp-highlight-item {
        flex-direction: row;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .ksap-wp-hero-section {
        padding: 112px 12px 72px;
    }

    .ksap-wp-title-sub {
        font-size: 1.3rem;
    }

    .ksap-wp-title-main {
        font-size: 2.2rem;
    }

    .ksap-wp-hero-desc {
        font-size: 1.05rem;
        padding: 0;
    }

    .ksap-wp-floating-badge-1,
    .ksap-wp-floating-badge-2,
    .ksap-wp-floating-badge-3,
    .ksap-wp-floating-badge-4 {
        padding: 8px 14px;
        font-size: 0.9rem;
    }

    .ksap-wp-floating-badge-1 {
        top: -8%;
        left: 5%;
    }

    .ksap-wp-floating-badge-2 {
        right: -5%;
    }

    .ksap-wp-floating-badge-3 {
        top: -8%;
        right: -5%;
    }

    .ksap-wp-floating-badge-4 {
        bottom: 18%;
        left: 12%;
    }

    .ksap-wp-highlight-item {
        flex-direction: row;
        align-items: center;
        text-align: left;
        justify-content: flex-start;
        padding: 5px 0;
    }

    .ksap-wp-icon-bulb {
        width: 60px;
        height: 60px;
        font-size: 2rem;
        flex-shrink: 0;
    }

    .ksap-wp-floating-container {
        flex-direction: column;
        gap: 12px;
        padding: 0 12px;
    }

    .ksap-wp-timer-wrapper {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .ksap-wp-timer {
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 6px 4px;
        font-size: 1.15rem;
    }

    .ksap-wp-floating-actions {
        width: 100%;
    }

    .ksap-wp-btn-primary {
        max-width: none;
    }

    .ksap-wp-detail-section {
        max-width: none;
        width: 100vw;
        margin-left: calc(50% - 50vw);
        margin-right: calc(50% - 50vw);
        padding: 0 0 32px;
    }

    .ksap-wp-img-wrapper {
        border-radius: 0;
        border-left: none;
        border-right: none;
    }

    .ksap-wp-modal-overlay {
        align-items: center !important;
        justify-content: center !important;
        padding: 16px;
    }

    .ksap-wp-modal-content {
        width: min(92vw, 420px);
        max-height: calc(100dvh - 32px);
        overflow: auto;
        margin: 0 auto;
    }
}
