/* Pretendard GOV Font Import */
@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/variable/pretendardvariable-gov.min.css');


/* CSS Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    letter-spacing: -0.07em;
}

/* Base Styles */
:root {
    --gradient-start: #1d2028;
    --gradient-end: #736bfb;
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.6);
    --letter-spacing-tight: -0.03em;
    --letter-spacing-wide: 0.15em;
    scrollbar-width: thin;
}

/* Animations */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(2.5em);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-2em);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes shimmer {
    0%, 100% {
        opacity: 0.6;
    }
    5% {
        opacity: 0.8;
    }
    11.11% {
        opacity: 0.6;
    }
}

html {
    font-size: 14px;
}

body {
    font-family: "Pretendard GOV Variable", "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: linear-gradient(350deg, var(--gradient-start) 65%, var(--gradient-end) 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
}

/* Layout */
.container {
    padding: 2em;
}

/* Hero Section */
.hero {
    min-height: 60vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4em 2em;
    max-width: 64em;
    margin: 0 auto;
}

/* Brand Title - Small Label Style */
.brand-title {
    font-size: 1em;
    font-weight: 500;
    letter-spacing: var(--letter-spacing-wide);
    text-transform: uppercase;
    margin: 0 auto 3em auto;
    display: flex;
    align-items: center;
    gap: 0.5em;
}

.shimmer-char {
    display: inline-block;
    opacity: 0;
    animation: fadeIn 0.5s ease forwards, shimmer 9s ease-in-out infinite;
}

.shimmer-char:nth-child(1) { animation-delay: 0.3s, 0s; }
.shimmer-char:nth-child(2) { animation-delay: 0.4s, 1s; }
.shimmer-char:nth-child(3) { animation-delay: 0.5s, 2s; }
.shimmer-char:nth-child(4) { animation-delay: 0.6s, 3s; }
.shimmer-char:nth-child(5) { animation-delay: 0.7s, 4s; }
.shimmer-char:nth-child(6) { animation-delay: 0.8s, 5s; }
.shimmer-char:nth-child(7) { animation-delay: 0.9s, 6s; }
.shimmer-char:nth-child(8) { animation-delay: 1.0s, 7s; }
.shimmer-char:nth-child(9) { animation-delay: 1.1s, 8s; }

/* Slogan Group */
.slogan-group {
    display: flex;
    flex-direction: column;
    gap: 2.5em;
}

/* Main Slogan - Large Editorial Style */
.slogan-main {
    display: flex;
    flex-direction: column;
    gap: 0.1em;
    overflow: hidden;
}

.slogan-line {
    font-size: clamp(2.5em, 8vw, 5em);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.02em;
    opacity: 0;
    animation: slideUp 1.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    perspective: 60em;
}

.slogan-line:nth-child(1) { animation-delay: 0.6s; }
.slogan-line:nth-child(2) { animation-delay: 0.9s; }
.slogan-line:nth-child(3) { animation-delay: 1.2s; }

/* Flap Animation */
.flap-wrapper {
    display: inline-block;
    position: relative;
    overflow: hidden;
    height: 1.2em;
    vertical-align: bottom;
}

.flap-text {
    display: block;
    transition: transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.flap-ko {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    transform: translateY(100%) rotateX(-90deg);
    transform-origin: top center;
}

/* Flapped state */
.slogan-line.flapped .flap-text:not(.flap-ko) {
    transform: translateY(-100%) rotateX(90deg);
}

.slogan-line.flapped .flap-ko {
    transform: translateY(0) rotateX(0deg);
}

/* Sub Slogan - Small with divider */
.slogan-sub {
    font-size: 0.85em;
    font-weight: 400;
    letter-spacing: var(--letter-spacing-wide);
    text-transform: uppercase;
    color: var(--text-secondary);
    padding-top: 2em;
    border-top: 0.07em solid rgba(255, 255, 255, 0.15);
    max-width: 25em;
    opacity: 0;
    animation: slideUp 1.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: 1.6s;
}

/* Apps Section */
.apps-section {
    margin: 0 auto;
    padding: 4em 2em;
    width: 100%;
    max-width: 64em;
}

/* Section Header - Editorial Style */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3em;
    padding-bottom: 1em;
    border-bottom: 0.07em solid rgba(255, 255, 255, 0.1);
    opacity: 0;
    animation: fadeIn 1.2s ease forwards;
    animation-delay: 2s;
}

.section-label {
    font-size: 0.75em;
    font-weight: 500;
    letter-spacing: var(--letter-spacing-wide);
    text-transform: uppercase;
    opacity: 0.6;
}

.section-number {
    font-size: 1em;
    font-weight: 400;
    opacity: 0.3;
}

.apps-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 2em;
    padding: 0 2em;
    justify-content: center;
}

/* App Card */
.app-card {
    backdrop-filter: blur(10em);
    background-color: #ffffff05;
    border-radius: 1.4em;
    padding: 2em;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1em;
    width: calc((100% - 2em) / 2);
    opacity: 0;
    animation: slideUp 1.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.app-card:nth-child(1) { animation-delay: 2.3s; }
.app-card:nth-child(2) { animation-delay: 2.6s; }

.app-card:hover {
    transform: translateY(-0.35em);
    box-shadow: 0 0.7em 2em rgba(0, 0, 0, 0.2);
}

.app-icon {
    width: 5.7em;
    height: 5.7em;
    border-radius: 1.3em;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-placeholder {
    width: 100%;
    height: 100%;
}
.icon-placeholder > img{
    width: 100%;
}
.app-name {
    font-size: 1.4em;
    font-weight: 600;
    margin: 0;
}

.app-description {
    font-size: 0.95em;
    opacity: 0.7;
    margin: 0;
    text-align: center;
    min-height: 2.5em;
}

/* App Status Badge */
.app-status {
    padding: 0.5em 1.2em;
    border-radius: 0.85em;
    font-size: 0.85em;
    font-weight: 500;
    letter-spacing: 0.035em;
}

.app-status.released {
    background: rgba(76, 175, 80, 0.2);
    color: #a8e6a1;
}

.app-status.coming-soon {
    background: rgb(219 219 219 / 20%);
    color: #cfcfcf;
}

/* Store Links */
.store-links {
    display: flex;
    gap: 0.8em;
    margin-top: 0.5em;
    flex-wrap: wrap;
    justify-content: center;
}

.store-btn {
    display: flex;
    align-items: center;
    gap: 0.5em;
    padding: 0.7em 1.2em;
    border-radius: 0.85em;
    text-decoration: none;
    font-size: 0.9em;
    font-weight: 500;
    transition: all 0.2s ease;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
}

.store-btn svg {
    width: 1.3em;
    height: 1.3em;
}

.store-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    transform: translateY(-0.15em);
}

/* Footer */
footer {
    font-size: 0.8em;
    letter-spacing: 0.07em;
    padding: 2em 0;
    text-align: center;
    margin: 4em auto;
    width: 100%;
    opacity: 0;
    animation: fadeIn 1.2s ease forwards;
    animation-delay: 3s;
}

@media screen and (max-width: 768px) {
    .hero {
        text-align: center;
        padding: 3em 1.5em;
    }

    .slogan-sub {
        margin: 0 auto;
    }

    .apps-section {
        text-align: center;
    }

    .section-header {
        flex-direction: column;
        gap: 0.5em;
        text-align: center;
    }

    .app-card {
        width: 100%;
    }
}

@media screen and (max-width: 480px) {
    html {
        font-size: 12px;
    }

    .slogan-line {
        font-size: 2.2em;
    }

    .apps-grid {
        padding: 0;
        gap: 1.5em;
    }

    .store-links {
        flex-direction: column;
        width: 100%;
    }

    .store-btn {
        width: 100%;
        justify-content: center;
    }
}