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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Noto Sans KR', sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo {
    display: flex;
    align-items: center;
    font-size: 1.5rem;
    font-weight: 700;
    color: #ff6b9d;
}

.nav-logo i {
    margin-right: 10px;
    font-size: 1.8rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-menu a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-menu a:hover {
    color: #ff6b9d;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: #ff6b9d;
    transition: width 0.3s ease;
}

.nav-menu a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 2;
}

.hero-text {
    color: white;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1.2;
    margin-bottom: 20px;
}

.title-line {
    display: block;
    opacity: 0;
    transform: translateY(50px);
    animation: slideUp 1s ease forwards;
}

.title-line:nth-child(2) {
    animation-delay: 0.3s;
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0;
    animation: fadeInUp 1s ease 0.6s forwards;
}

.cta-button {
    background: linear-gradient(45deg, #ff6b9d, #ff8fab);
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    opacity: 0;
    animation: fadeInUp 1s ease 0.9s forwards;
    box-shadow: 0 10px 30px rgba(255, 107, 157, 0.3);
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(255, 107, 157, 0.4);
}

.hero-visual {
    position: relative;
    height: 400px;
}

/* Skin Analyzer Styles */
.skin-analyzer {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    max-width: 500px;
    margin: 0 auto;
}

.analyzer-header {
    text-align: center;
    margin-bottom: 25px;
}

.analyzer-header h3 {
    color: #333;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.analyzer-header p {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.5;
}

.upload-area {
    border: 2px dashed #ff6b9d;
    border-radius: 15px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(255, 107, 157, 0.05);
    margin-bottom: 20px;
}

.upload-area:hover {
    border-color: #ff8fab;
    background: rgba(255, 107, 157, 0.1);
    transform: translateY(-2px);
}

.upload-area.dragover {
    border-color: #ff8fab;
    background: rgba(255, 107, 157, 0.15);
    transform: scale(1.02);
}

.upload-content i {
    font-size: 3rem;
    color: #ff6b9d;
    margin-bottom: 15px;
    display: block;
}

.upload-content p {
    color: #666;
    font-size: 1rem;
    margin: 0;
}

.analysis-result {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 20px;
    animation: slideUpFade 0.5s ease;
}

.result-header h4 {
    color: #333;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 20px;
    text-align: center;
}

.skin-type, .skin-score, .recommended-brands {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding: 10px 0;
    border-bottom: 1px solid #e9ecef;
}

.skin-type:last-child, .skin-score:last-child, .recommended-brands:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.type-label, .score-label, .brands-label {
    font-weight: 600;
    color: #333;
    font-size: 0.9rem;
}

.type-value, .score-value {
    font-weight: 700;
    color: #ff6b9d;
    font-size: 1rem;
}

.brands-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    max-width: 200px;
}

.brand-tag {
    background: #ff6b9d;
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.analyze-btn {
    width: 100%;
    background: linear-gradient(45deg, #ff6b9d, #ff8fab);
    border: none;
    padding: 15px;
    border-radius: 15px;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(255, 107, 157, 0.3);
}

.analyze-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 107, 157, 0.4);
}

.analyze-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.analyzing {
    position: relative;
    overflow: hidden;
}

.analyzing::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: loading 1.5s infinite;
}

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

@keyframes slideUpFade {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.floating-item {
    position: absolute;
    font-size: 3rem;
    animation: float 6s ease-in-out infinite;
}

.item-1 {
    top: 10%;
    left: 20%;
    animation-delay: 0s;
}

.item-2 {
    top: 30%;
    right: 20%;
    animation-delay: 1s;
}

.item-3 {
    bottom: 30%;
    left: 10%;
    animation-delay: 2s;
}

.item-4 {
    bottom: 10%;
    right: 30%;
    animation-delay: 3s;
}

.item-5 {
    top: 50%;
    left: 50%;
    animation-delay: 4s;
}

.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    color: white;
    opacity: 0;
    animation: fadeInUp 1s ease 1.2s forwards;
}

.scroll-line {
    width: 2px;
    height: 40px;
    background: white;
    margin-bottom: 10px;
    animation: scrollPulse 2s ease-in-out infinite;
}

/* Stats Section */
.stats-section {
    padding: 100px 0;
    background: #f8f9fa;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.stat-item {
    text-align: center;
    padding: 40px 20px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.stat-item:hover {
    transform: translateY(-10px);
}

.stat-number {
    font-size: 3rem;
    font-weight: 900;
    color: #ff6b9d;
    margin-bottom: 10px;
}

.stat-label {
    font-size: 1.1rem;
    color: #666;
    font-weight: 500;
}

/* Language Selector */
.language-selector {
    display: flex;
    gap: 10px;
}

.lang-btn {
    background: transparent;
    border: 2px solid #ff6b9d;
    color: #ff6b9d;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.lang-btn.active {
    background: #ff6b9d;
    color: white;
}

.lang-btn:hover {
    background: #ff6b9d;
    color: white;
}

/* Brands Section */
.brands-section {
    padding: 100px 0;
    background: white;
}

.section-header {
    text-align: center;
    margin-bottom: 80px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
}

.section-subtitle {
    font-size: 1.2rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

.brands-container {
    overflow: hidden;
    position: relative;
}

.brands-scroll {
    display: flex;
    gap: 30px;
    animation: scroll 30s linear infinite;
    width: calc(300px * 44); /* 22 brands * 2 * 300px */
}

.brands-scroll:hover {
    animation-play-state: paused;
}

.brand-card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    min-width: 300px;
    flex-shrink: 0;
}

.brand-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

.brand-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(45deg, #ff6b9d, #ff8fab);
}

.brand-logo {
    width: 80px;
    height: 80px;
    background: linear-gradient(45deg, #ff6b9d, #ff8fab);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    font-size: 2rem;
    color: white;
}

.brand-name {
    font-size: 1.5rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
}

.brand-description {
    color: #666;
    line-height: 1.6;
    margin-bottom: 20px;
}

.brand-features {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.feature-tag {
    background: #f0f0f0;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    color: #666;
}

/* About Section */
.about-section {
    padding: 100px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-text h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 30px;
}

.about-text p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 40px;
    opacity: 0.9;
}

.features {
    display: flex;
    gap: 30px;
}

.feature {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.feature i {
    font-size: 2rem;
    margin-bottom: 10px;
    color: #ff6b9d;
}

.about-visual {
    position: relative;
    height: 400px;
}

.visual-element {
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Contact Section */
.contact-section {
    padding: 100px 0;
    background: #f8f9fa;
}

.contact-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.contact-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
}

.contact-content p {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 50px;
}

/* Contact Form */
.contact-form {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 50px;
    text-align: left;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    font-size: 1rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: 'Noto Sans KR', sans-serif;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #ff6b9d;
    box-shadow: 0 0 0 3px rgba(255, 107, 157, 0.1);
}

/* Country Autocomplete Styles */
.country-autocomplete {
    position: relative;
    width: 100%;
}

.country-autocomplete input[type="text"] {
    width: 100%;
    padding: 15px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: 'Noto Sans KR', sans-serif;
}

.country-autocomplete input[type="text"]:focus {
    outline: none;
    border-color: #ff6b9d;
    box-shadow: 0 0 0 3px rgba(255, 107, 157, 0.1);
}

.autocomplete-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 2px solid #e9ecef;
    border-top: none;
    border-radius: 0 0 10px 10px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.autocomplete-dropdown.show {
    display: block;
}

.autocomplete-item {
    padding: 12px 15px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid #f0f0f0;
}

.autocomplete-item:last-child {
    border-bottom: none;
}

.autocomplete-item:hover {
    background-color: #f8f9fa;
}

.autocomplete-item.selected {
    background-color: #ff6b9d;
    color: white;
}

.autocomplete-item.highlighted {
    background-color: rgba(255, 107, 157, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.submit-btn {
    width: 100%;
    background: linear-gradient(45deg, #ff6b9d, #ff8fab);
    border: none;
    padding: 15px;
    border-radius: 15px;
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 5px 15px rgba(255, 107, 157, 0.3);
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 107, 157, 0.4);
}

.submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.submit-btn.sending {
    position: relative;
    overflow: hidden;
}

.submit-btn.sending::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: loading 1.5s infinite;
}

.contact-info {
    display: flex;
    justify-content: center;
    gap: 60px;
    flex-wrap: wrap;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 1.1rem;
    color: #333;
}

.contact-item i {
    color: #ff6b9d;
    font-size: 1.5rem;
}

/* Footer */
.footer {
    background: #333;
    color: white;
    padding: 40px 0;
    text-align: center;
}

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

.footer-logo {
    display: flex;
    align-items: center;
    font-size: 1.2rem;
    font-weight: 600;
}

.footer-logo i {
    margin-right: 10px;
    color: #ff6b9d;
}

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

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

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes scrollPulse {
    0%, 100% {
        opacity: 1;
        transform: scaleY(1);
    }
    50% {
        opacity: 0.5;
        transform: scaleY(0.8);
    }
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(calc(-300px * 22 - 30px * 21));
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }
    
    .hero-visual {
        height: 350px;
    }
    
    .skin-analyzer {
        padding: 20px;
        max-width: 100%;
    }
    
    .upload-area {
        padding: 30px 15px;
    }
    
    .upload-content i {
        font-size: 2.5rem;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .about-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .features {
        justify-content: center;
    }
    
    .contact-info {
        flex-direction: column;
        gap: 30px;
    }
    
    .contact-form {
        padding: 30px 20px;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 20px;
    }
    
    .brands-scroll {
        animation-duration: 20s;
    }
    
    .brand-card {
        min-width: 250px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .floating-item {
        font-size: 2rem;
    }
    
    .language-selector {
        display: none;
    }
}
