/* PHILOSTAR Landing Page Styles - v3.0 */
/* Cross-browser compatible styles */

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    width: 100%;
    max-width: 100%;
    height: 100%;
    overflow-x: hidden;
}

body {
    width: 100%;
    max-width: 100vw;
    min-height: 100vh;
    min-height: -webkit-fill-available;

    /* Gradient background with fallback */
    background: rgb(29, 8, 71);
    background: -webkit-linear-gradient(to bottom right, rgb(29, 8, 71), rgb(121, 118, 232));
    background: -moz-linear-gradient(to bottom right, rgb(29, 8, 71), rgb(121, 118, 232));
    background: -o-linear-gradient(to bottom right, rgb(29, 8, 71), rgb(121, 118, 232));
    background: linear-gradient(to bottom right, rgb(29, 8, 71), rgb(121, 118, 232));
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;

    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;

    overflow-x: hidden;
    position: relative;
    margin: 0;
    padding: 0;
}

/* Contact Button (Top Right) */
.contact-btn {
    position: fixed;
    top: 2rem;
    right: 5.5rem;
    z-index: 100;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.5);
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-transition: all 0.3s ease;
    -moz-transition: all 0.3s ease;
    -o-transition: all 0.3s ease;
    transition: all 0.3s ease;
    font-family: inherit;
}

.contact-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.8);
    color: white;
}

/* Language Switcher (Bottom Right) */
.language-switcher {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 100;
    display: -webkit-box;
    display: -webkit-flex;
    display: -moz-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -webkit-align-items: center;
    -moz-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    gap: 0.5rem;
}

.lang-btn {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    font-weight: 400;
    cursor: pointer;
    padding: 0.3rem 0.5rem;
    -webkit-transition: color 0.3s ease;
    -moz-transition: color 0.3s ease;
    -o-transition: color 0.3s ease;
    transition: color 0.3s ease;
    font-family: inherit;
}

.lang-btn:hover {
    color: white;
    color: rgba(255, 255, 255, 1);
}

.lang-btn.active {
    color: white;
    color: rgba(255, 255, 255, 1);
    font-weight: 500;
}

.lang-separator {
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
    margin: 0;
    padding: 0;
}

/* Logo Area (Top Left) */
.logo_area {
    position: fixed;
    top: 2rem;
    left: 2rem;
    z-index: 100;
}

.logo_image {
    height: 60px;
    width: auto;
    display: block;
    filter: brightness(0) invert(1);
    -webkit-filter: brightness(0) invert(1);
    opacity: 0.6;
}

.logo_text {
    font-size: 14px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.8);
    letter-spacing: 0.5px;
    font-style: italic;
}

/* Container Layout */
.outer_div {
    display: -webkit-box;
    display: -webkit-flex;
    display: -moz-box;
    display: -ms-flexbox;
    display: flex;

    -webkit-box-pack: center;
    -webkit-justify-content: center;
    -moz-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;

    -webkit-box-align: center;
    -webkit-align-items: center;
    -moz-box-align: center;
    -ms-flex-align: center;
    align-items: center;

    min-height: 100vh;
    min-height: -webkit-fill-available;
    width: 100%;
    max-width: 100%;
    padding: 2rem 1rem;
    overflow-x: hidden;
    box-sizing: border-box;
}

.my_gradient_5 {
    text-align: center;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    box-sizing: border-box;
}

/* Concept Copy - 강 (Strong) */
.concept_copy {
    margin-top: 6em;
    margin-bottom: 4em;
}

.sub_copy {
    font-size: 16px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1.2em;
    letter-spacing: 1px;
}

.main_copy {
    font-size: 65px;
    font-size: -webkit-calc(32px + 4vw);
    font-size: -moz-calc(32px + 4vw);
    font-size: calc(32px + 4vw);
    font-size: clamp(32px, 8vw, 65px);

    font-weight: 400;
    color: white;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.3;
    margin: 0;
    padding: 0;
}

/* Logo Chart Container - 강 (Strong) */
#logo-chart {
    margin-top: 3.5em;
    margin-bottom: 3.5em;
    width: 100%;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    overflow: hidden;
    box-sizing: border-box;
}

.logo-image {
    display: block;
    margin: 0 auto;
    max-width: 100%;
    height: auto;
    -webkit-filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
}

#logo-chart svg {
    -webkit-filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
    display: block;
    margin: 0 auto;
    max-width: 100%;
    height: auto;
}

/* Graph Info - 약 (Weak) */
.graph_info {
    margin-top: 2.5em;
    margin-bottom: 1.5em;
    font-size: 11px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.8);
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 1rem;
}

.graph_info p {
    margin: 0;
}

.graph_info .source {
    margin-top: 0.8em;
    font-size: 10px;
    font-style: italic;
    color: rgba(255, 255, 255, 0.8);
}

/* Email Section - 중 (Medium) */
.email_text {
    margin-top: 7em;
    margin-bottom: 2em;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
}

.email_text a {
    color: rgba(255, 255, 255, 0.8) !important;
    text-decoration: none !important;
    -webkit-transition: color 0.3s ease;
    -moz-transition: color 0.3s ease;
    -o-transition: color 0.3s ease;
    transition: color 0.3s ease;
}

.email_text a:hover {
    color: white !important;
    color: rgba(255, 255, 255, 1) !important;
    text-decoration: underline !important;
}

.email_text a:visited {
    color: rgba(255, 255, 255, 0.8) !important;
}

.email_text a:active {
    color: white !important;
}

/* Copyright - 약 (Weak) */
.copyright {
    margin-top: 5em;
    margin-bottom: 3em;
    font-size: 10px;
    color: rgba(255, 255, 255, 0.8);
}

.copyright p {
    margin: 0;
}

.ai_credit {
    margin-top: 0.5em !important;
    font-size: 10px;
    color: rgba(255, 255, 255, 0.8);
}

/* AI Technologies - 약 (Weak) - Fixed Bottom Left */
.ai_tech {
    position: fixed;
    bottom: 0.8rem;
    left: 2rem;
    font-size: 9px;
    color: rgba(255, 255, 255, 0.8);
    text-align: left;
    z-index: 50;
}

.ai_tech p {
    margin: 0;
    line-height: 1.4;
}

.tech_detail {
    margin-top: 0.3em !important;
    font-style: italic;
}

/* Responsive Media Queries */

/* Desktop: 1280px and below */
@media (max-width: 1280px) {
    .logo_text {
        font-size: 13px;
    }

    .sub_copy {
        font-size: 15px;
    }

    .main_copy {
        font-size: 60px;
        font-size: -webkit-calc(40px + 3vw);
        font-size: -moz-calc(40px + 3vw);
        font-size: calc(40px + 3vw);
        font-size: clamp(40px, 7vw, 60px);
    }

    #logo-chart {
        margin-top: 1.8em !important;
    }

    .email_text {
        font-size: 13px;
    }

    .graph_info {
        font-size: 11px;
        max-width: 600px;
    }
}

/* Tablet: 768px and below */
@media (max-width: 768px) {
    body {
        background-attachment: scroll;
    }

    .contact-btn {
        top: 1.5rem;
        right: 5rem;
        font-size: 13px;
        padding: 0.4rem 0.8rem;
        height: 38px;
    }

    .language-switcher {
        bottom: 1.5rem;
        right: 1.5rem;
    }

    .ai_tech {
        bottom: 0.5rem;
        left: 1.5rem;
    }

    .lang-btn {
        font-size: 13px;
        padding: 0.25rem 0.4rem;
    }

    .lang-separator {
        font-size: 13px;
    }

    .logo_area {
        top: 1.5rem;
        left: 1.5rem;
    }

    .logo_text {
        font-size: 12px;
    }

    .outer_div {
        padding: 1.5rem 1rem;
    }

    .concept_copy {
        margin-bottom: 2.5em;
    }

    .sub_copy {
        font-size: 14px;
    }

    .main_copy {
        font-size: 48px;
        font-size: -webkit-calc(28px + 2.5vw);
        font-size: -moz-calc(28px + 2.5vw);
        font-size: calc(28px + 2.5vw);
        font-size: clamp(28px, 6vw, 48px);
    }

    #logo-chart {
        margin-top: 1.5em !important;
    }

    .email_text {
        font-size: 12px;
    }

    .graph_info {
        font-size: 10px;
        max-width: 90%;
    }

    .copyright {
        margin-bottom: 4em;
    }
}

/* Mobile: 480px and below */
@media (max-width: 480px) {
    body {
        max-width: 100vw;
        overflow-x: hidden;
    }

    .contact-btn {
        top: 1rem;
        right: 4.5rem;
        font-size: 12px;
        padding: 0.3rem 0.6rem;
        height: 36px;
    }

    .language-switcher {
        bottom: 1rem;
        right: 1rem;
    }

    .ai_tech {
        bottom: 0.5rem;
        left: 1rem;
    }

    .lang-btn {
        font-size: 12px;
        padding: 0.2rem 0.3rem;
    }

    .lang-separator {
        font-size: 12px;
    }

    .logo_area {
        top: 1rem;
        left: 1rem;
    }

    .logo_text {
        font-size: 11px;
    }

    .outer_div {
        padding: 1rem 0.5rem;
        max-width: 100%;
        overflow-x: hidden;
    }

    .my_gradient_5 {
        padding: 0 0.5rem;
        max-width: 100%;
    }

    .concept_copy {
        margin-bottom: 2em;
    }

    .sub_copy {
        font-size: 13px;
    }

    .main_copy {
        font-size: 36px;
        font-size: -webkit-calc(22px + 2vw);
        font-size: -moz-calc(22px + 2vw);
        font-size: calc(22px + 2vw);
        font-size: clamp(22px, 5.5vw, 36px);
    }

    #logo-chart {
        margin-top: 1.2em !important;
        padding: 0;
        max-width: 100%;
    }

    #logo-chart svg {
        max-width: 100%;
        width: 100%;
    }

    .email_text {
        margin-top: 1.5em;
        margin-bottom: 1.5em;
        font-size: 11px;
    }

    .graph_info {
        font-size: 9px;
        margin-top: 1em;
        margin-bottom: 1em;
        padding: 0 0.8em;
        max-width: 100%;
    }

    .copyright {
        font-size: 9px;
        margin-bottom: 5em;
    }

    .ai_tech {
        bottom: 0.5rem;
        right: 1rem;
        font-size: 8px;
    }
}

/* iOS Safari specific fixes */
@supports (-webkit-touch-callout: none) {
    body {
        min-height: -webkit-fill-available;
    }

    .outer_div {
        min-height: -webkit-fill-available;
    }
}

/* SPA Section Pages - Override for non-home pages */
body.page-section {
    background: #ffffff;
}

body.page-section .logo_area {
    position: fixed;
    top: 1.5rem;
    left: 2rem;
}

body.page-section .logo_image {
    filter: none;
    -webkit-filter: none;
    opacity: 1;
    height: 50px;
}

body.page-section .contact-btn {
    background: #7B1FA2;
    border: 1px solid #7B1FA2;
    color: #ffffff;
}

body.page-section .contact-btn:hover {
    background: #5a1480;
    border-color: #5a1480;
}

body.page-section .menu-btn .menu-icon,
body.page-section .menu-btn .menu-icon::before,
body.page-section .menu-btn .menu-icon::after {
    background-color: #212121;
}

body.page-section .language-switcher,
body.page-section .ai_tech {
    display: none;
}
