:root {
    --bg-main: #0f0f0f;
    --bg-sub: #080808;
    --card-bg: #1a1a1b;
    --accent: #00ffa3;
    --accent-rgb: 0, 255, 163;
    --text-white: #ffffff;
    --text-gray: #adadb8;
    --header-height: 120px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html {
    height: 100%;
    scroll-behavior: smooth;
}

body {
    height: 100%;
    background-color: #0f0f0f;
    color: #ffffff;
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    opacity: 0; 
    overflow-x: hidden;
}

main {
    flex: 1;
    width: 100%;
    display: block;
}

.fade-in {
    animation: pageFadeIn 0.6s ease-out forwards;
}

@keyframes pageFadeIn {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

.fade-out {
    animation: pageFadeOut 0.5s ease-in forwards !important;
}

@keyframes pageFadeOut {
    0% { opacity: 1; }
    100% { opacity: 0; }
}

@keyframes fadeInUp {
    0% { opacity: 0; transform: translateY(40px); }
    100% { opacity: 1; transform: translateY(0); }
}

.clip-card.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.clip-card.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

@keyframes frameBreathing {
    0% { opacity: 0.3; filter: drop-shadow(0 0 2px var(--accent)); }
    50% { opacity: 1; filter: drop-shadow(0 0 15px var(--accent)); }
    100% { opacity: 0.3; filter: drop-shadow(0 0 2px var(--accent)); }
}

@keyframes modalBgIn {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

@keyframes modalContentIn {
    0% { opacity: 0; transform: scale(0.9) translateY(40px); }
    100% { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes modalContentOut {
    0% { opacity: 1; transform: scale(1) translateY(0); }
    100% { opacity: 0; transform: scale(0.95) translateY(20px); }
}

header {
    height: 120px;
    width: 100%;
    background-color: #0f0f0f;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-left: 8%;
    padding-right: 8%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    flex-shrink: 0;
}

.logo {
    font-size: 1.85rem;
    font-weight: 900;
    color: #00ffa3;
    text-decoration: none;
    letter-spacing: -1.5px;
    display: inline-block;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.02);
}

nav {
    display: flex;
    align-items: center;
}

nav a {
    text-decoration: none;
    color: #adadb8;
    font-weight: 600;
    font-size: 1.15rem;
    margin-left: 50px;
    transition: color 0.3s ease;
    display: inline-block;
}

nav a:hover {
    color: #ffffff;
}

nav a.active {
    color: #ffffff;
    position: relative;
}

nav a.active::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: #00ffa3;
    border-radius: 2px;
}

.hero-full {
    min-height: calc(100vh - 120px);
    background-color: #0f0f0f;
    display: flex;
    justify-content: center; 
    align-items: center;     
    padding-left: 8%;
    padding-right: 8%;
    position: relative;
    overflow: hidden;
}

.corner-frame {
    position: absolute;
    width: 50px;
    height: 50px;
    border-color: var(--accent);
    border-style: solid;
    z-index: 5;
    pointer-events: none;
    animation: frameBreathing 3s ease-in-out infinite;
}

.top-left { top: 40px; left: 40px; border-width: 4px 0 0 4px; }
.top-right { top: 40px; right: 40px; border-width: 4px 4px 0 0; }
.bottom-left { bottom: 40px; left: 40px; border-width: 0 0 4px 4px; }
.bottom-right { bottom: 40px; right: 40px; border-width: 0 4px 4px 0; }

.hero-content {
    max-width: 800px;
    text-align: center; 
    animation: fadeInUp 1s ease-out;
    position: relative;
    z-index: 10;
}

.badge {
    color: #00ffa3;
    font-size: 0.7rem;
    font-weight: 400;
    letter-spacing: 6px;
    margin-bottom: 15px;
    display: block;
    text-transform: uppercase;
    opacity: 0.7;
}

.hero-content h1 {
    font-size: 4.2rem;
    line-height: 1.1;
    margin-bottom: 25px;
    font-weight: 900;
    color: #ffffff;
}

.highlight {
    color: #00ffa3;
}

.hero-content p {
    font-size: 1.2rem;
    color: #adadb8;
    margin-bottom: 35px;
    line-height: 1.8;
}

.hero-btns {
    display: flex;
    justify-content: center; 
    gap: 20px;
}

.cta-btn {
    padding-top: 16px;
    padding-bottom: 16px;
    padding-left: 42px;
    padding-right: 42px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    display: inline-block;
    transition: all 0.4s ease;
    cursor: pointer;
}

.cta-btn.primary {
    background-color: #00ffa3;
    color: #000000;
}

.cta-btn.secondary {
    background-color: transparent;
    border: 2px solid #ffffff;
    color: #ffffff;
}

.cta-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 255, 163, 0.2);
}

.filter-bar {
    padding-top: 40px;
    padding-bottom: 30px;
    padding-left: 8%;
    padding-right: 8%;
    display: flex;
    gap: 15px;
    background-color: #0f0f0f;
}

.filter-btn {
    background-color: #26262c;
    border: none;
    color: #adadb8;
    padding-top: 12px;
    padding-bottom: 12px;
    padding-left: 28px;
    padding-right: 28px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 700;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background-color: #32323a;
    color: #ffffff;
}

.filter-btn.active {
    background-color: #00ffa3;
    color: #000000;
}

.container {
    display: grid;
    grid-template-columns: repeat(4, 1fr); 
    gap: 30px;
    padding-left: 8%;
    padding-right: 8%;
    padding-bottom: 50px;
}

.status-msg {
    grid-column: 1 / -1;
    text-align: center;
    color: #adadb8;
    font-size: 1.1rem;
    padding: 60px 20px;
}

.clip-card {
    background-color: #1a1a1b;
    border-radius: 18px;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1), 
                box-shadow 0.4s ease, 
                border-color 0.4s ease;
    transform: scale(1);
    will-change: transform;
}

.clip-card:hover {
    transform: scale(1.04) translateY(-10px) !important; 
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.9);
    border-color: rgba(0, 255, 163, 0.5);
    z-index: 50;
}

.video-wrap {
    position: relative;
    padding-bottom: 56.25%;
    background-color: #000000;
}

.video-wrap img {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    object-fit: cover;
}

.play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 3rem;
    color: #ffffff;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.clip-card:hover .play-overlay {
    opacity: 1;
}

.info {
    padding-top: 25px;
    padding-bottom: 25px;
    padding-left: 25px;
    padding-right: 25px;
    background-color: #1a1a1b;
}

.game-name {
    color: #00ffa3;
    font-size: 0.8rem;
    font-weight: 800;
    display: block;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.4;
}

.load-more-container {
    display: flex;
    justify-content: center;
    padding-top: 20px;
    padding-bottom: 100px;
    width: 100%;
}

.load-more-btn {
    background-color: transparent;
    border-top-width: 1px;
    border-bottom-width: 1px;
    border-left-width: 1px;
    border-right-width: 1px;
    border-style: solid;
    border-color: #00ffa3;
    color: #00ffa3;
    padding-top: 15px;
    padding-bottom: 15px;
    padding-left: 60px;
    padding-right: 60px;
    border-radius: 40px;
    font-weight: 700;
    font-size: 1.1rem;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.load-more-btn:hover {
    background-color: #00ffa3;
    color: #000000;
    box-shadow: 0 0 25px rgba(0, 255, 163, 0.4);
    transform: translateY(-5px);
}

footer {
    padding-top: 15px;
    padding-bottom: 15px;
    padding-left: 6%;
    padding-right: 6%;
    background-color: #080808;
    position: relative;
    text-align: center;
    width: 100%;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(0, 255, 163, 0.6) 50%, transparent 100%);
    box-shadow: 0 -2px 10px rgba(0, 255, 163, 0.3);
}

.copyright {
    color: #5f5f5f;
    font-size: 0.9rem;
    letter-spacing: 1px;
    font-weight: 600;
}

.modal-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important; 
    height: 100vh !important;
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 999999 !important; 
    display: flex !important;
    justify-content: center !important; 
    align-items: center !important; 
    padding: 20px;
    animation: modalBgIn 0.4s ease-out forwards;
    overflow: hidden !important;
    transform: none !important;
    margin: 0 !important;
}

.modal-content-layer {
    background-color: #1a1a1b;
    width: 100%;
    max-width: 1050px;
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 0 65px rgba(0, 255, 163, 0.22), 
                0 0 35px rgba(0, 255, 163, 0.12),
                0 0 0 1px rgba(0, 255, 163, 0.35);
    animation: modalContentIn 0.5s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
}

.modal-overlay.closing {
    animation: modalBgIn 0.4s ease-out reverse forwards;
}

.modal-overlay.closing .modal-content-layer {
    animation: modalContentOut 0.4s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
}

.close-btn-layer {
    position: absolute;
    right: 25px;
    top: 15px;
    font-size: 3.5rem;
    color: #ffffff;
    cursor: pointer;
    z-index: 10001;
    line-height: 1;
    transition: color 0.3s, transform 0.3s;
}

.close-btn-layer:hover {
    color: var(--accent);
    transform: rotate(90deg);
}

.video-frame-wrap {
    position: relative;
    padding-bottom: 56.25%; 
    background-color: #000000;
}

.video-frame-wrap iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.modal-info-layer {
    padding-top: 35px;
    padding-bottom: 35px;
    padding-left: 40px;
    padding-right: 40px;
    overflow-y: auto;
    background-color: #1a1a1b;
}

.modal-info-layer h2 {
    font-size: 1.8rem;
    margin-bottom: 10px;
    color: #ffffff;
}

.modal-meta-layer {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    color: #adadb8;
    font-size: 0.95rem;
}

.game-tag-neon {
    color: #00ffa3;
    font-weight: 700;
    text-transform: uppercase;
}

.modal-desc-layer {
    color: #adadb8;
    line-height: 1.8;
    font-size: 1.05rem;
}

@media (max-width: 1200px) {
    .container { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 900px) {
    header { height: 95px; padding-left: 5%; padding-right: 5%; }
    .container { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
    .container { grid-template-columns: repeat(1, 1fr); }
    .hero-content h1 { font-size: 2.8rem; }
    .load-more-btn { width: 100%; }
    .modal-content-layer { border-radius: 12px; }
}