:root {
    --mobile-padding: 15px;
    --section-margin-mobile: 1.5rem;
}

.navbar {
    background: linear-gradient(to right, #2e7d32, #4caf50);
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    min-height: 80px; /* ????????????? ?????? ????? */
}

.nav-container {
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 10px;
    width: 100%;
    height: 100%;
}

/* ????????? ??? ???? ? ???????? */
.logo-container {
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    height: 100%;
}

.logo {
    color: white;
    font-weight: bold;
    font-size: 1.8rem;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    height: 100%;
}

.logo-icon {
    width: 24px;
    height: 24px;
}

.site-logo {
    height: 50px;
    width: auto;
    margin-right: 10px;
    vertical-align: middle;
    object-fit: contain;
}

.site-name {
    vertical-align: middle;
    line-height: 1;
}

/* ????????????? ?????? */
.nav-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    height: 100%;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 1.3em;
    line-height: 1;
}

.nav-links a:hover {
    background-color: rgba(255,255,255,0.2);
}

.nav-links a.active {
    background-color: rgba(255,255,255,0.3);
}

/* ?????? ???? ??? ????????? */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    align-items: center;
    height: 100%;
}

/* ????????? ??? ????????? */
@media (max-width: 768px) {
    .navbar {
        min-height: 70px;
        padding: 0;
    }
    
    .menu-toggle {
        display: flex;
    }
    
    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: #2e7d32;
        flex-direction: column;
        padding: 1rem;
        gap: 0.5rem;
        box-shadow: 0 5px 10px rgba(0,0,0,0.2);
        transform: translateY(-150%);
        transition: transform 0.3s ease-in-out;
        height: auto;
    }
    
    .nav-links.active {
        transform: translateY(0);
    }
    
    .nav-links a {
        padding: 0.8rem;
        justify-content: center;
    }
    
    .nav-container {
        padding: 0 var(--mobile-padding);
    }
    
    .logo {
        font-size: 1.4rem;
    }
    
    .logo-icon {
        width: 20px;
        height: 20px;
    }
    
    .site-logo {
        height: 40px;
    }
    
    .text-logo {
        font-size: 1.2rem;
    }
}

/* ??? ????? ????????? ??????? */
@media (max-width: 480px) {
    .navbar {
        min-height: 60px;
    }
    
    .logo-container {
        gap: 5px;
    }
    
    .text-logo {
        font-size: 1rem;
    }
    
    .site-logo {
        height: 32px;
    }
    
    .nav-links {
        top: 60px;
    }
}

/* iPhone 14 ? ???????? */
@media (max-width: 430px) {
    .navbar {
        padding-top: env(safe-area-inset-top);
        min-height: calc(60px + env(safe-area-inset-top));
    }
    
    .nav-container {
        padding: 0 max(env(safe-area-inset-left), 15px);
    }
    
    .site-logo {
        height: 30px;
    }
    
    .text-logo {
        font-size: 1.1rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 150px;
    }
    
    .nav-links {
        top: calc(60px + env(safe-area-inset-top));
    }
}

/* ???????? ????????????? ????????????? ??? ???? ????????? */
.navbar * {
    display: flex;
    align-items: center;
}

/* ??? ????????? ????????? */
.site-name,
.text-logo,
.nav-links a {
    display: flex;
    align-items: center;
    margin: 0;
}