:root {
    --primary: #1a4f72;
    --secondary: #fd7e14;
    --accent: #c92a2a;
    --light: #f8f9fa;
    --dark: #212529;
    --gray: #6c757d;
    --light-gray: #e9ecef;
}

/* 기본값으로 다크모드 설정 */
body {
    --light: #212529;
    --dark: #ffffff;
    --light-gray: #343a40;
    --body-bg: #121212;
    --card-bg: #2d3748;
    --card-border: rgba(255, 255, 255, 0.1);
    --footer-bg: #1a202c;
}

body.light-mode {
    --light: #f8f9fa;
    --dark: #212529;
    --light-gray: #e9ecef;
    --body-bg: #ffffff;
    --card-bg: #ffffff;
    --card-border: rgba(0, 0, 0, 0.1);
    --footer-bg: #212529;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans KR', sans-serif;
    line-height: 1.6;
    color: var(--dark);
    background-color: var(--body-bg);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* 다크모드 토글 스타일 */
.theme-toggle {
    background: none;
    border: none;
    color: var(--dark);
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0.5rem;
    transition: color 0.3s;
    display: flex;
    align-items: center;
}

.theme-toggle:hover {
    color: var(--primary);
}

.theme-toggle i {
    margin-right: 0.5rem;
}

/* 헤더 스타일 */
header {
    padding: 1.5rem 0;
    position: sticky;
    top: 0;
    background-color: var(--light);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    z-index: 100;
}

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

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

.logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo img {
    max-height: 40px; /* 로고 크기 증가 */
    max-width: 190px; /* 최대 너비 증가 */
    width: auto;
    object-fit: contain;
}

/* 기존 로고 텍스트 스타일은 남겨두지만 사용하지 않음 */
.logo span.rok {
    color: var(--primary);
}

.logo span.foss {
    color: var(--secondary);
}

.nav-links {
    display: flex;
    gap: 1.5rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--primary);
}

/* 이미 사용 중이신 코드 (변경 없음) */
.hero {
    position: relative;
    overflow: hidden;
    margin-bottom: 2rem;
    border-radius: 0;
    color: white;
    text-align: center;
    padding: 4rem 0;
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -1;
    filter: blur(3px);
}

/* 오버레이 전용 요소 */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3); /* 투명도는 취향껏 조절 */
    z-index: -1; /* 영상 위, 텍스트 아래에 위치 */
}

.hero .container {
    position: relative;
    z-index: 1;
}
    

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto 2rem;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.btn {
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s;
}

.btn-primary {
    background-color: var(--secondary);
    color: white;
}

.btn-primary:hover {
    background-color: #e67700;
}

.btn-outline {
    background-color: transparent;
    color: white;
    border: 1px solid white;
}

.btn-outline:hover {
    background-color: rgba(255,255,255,0.1);
}

/* 메인 콘텐츠 */
.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin: 4rem 0;
}

.feature-card {
    background-color: var(--light);
    border: 1px solid var(--light-gray);
    border-radius: 1rem;
    padding: 2rem;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    height: 100%;  /* 카드 높이 통일 */
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(255, 255, 255, 0.1);
}

.feature-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 4rem;
    height: 4rem;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    margin-bottom: 1.5rem;
    color: #ffffff;
}

.feature-card h3 {
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.feature-card p {
    flex-grow: 1;  /* 설명 텍스트가 가능한 공간을 채우도록 */
}

.card-button-container {
    margin-top: 1.5rem;
    text-align: center;
}

.card-button {
    display: inline-block;
    width: 100%;  /* 버튼 너비 통일 */
    max-width: 200px; /* 최대 너비 설정 */
    padding: 0.75rem 1rem;
    text-align: center;
    border-radius: 0.5rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s;
}

.btn-primary.card-button {
    background-color: var(--secondary);
    color: white;
}

.btn-primary.card-button:hover {
    background-color: #e67700;
}

/* 프로젝트 섹션 */
.section-title {
    text-align: center;
    margin: 4rem 0 2rem;
    font-size: 2rem;
    color: var(--primary);
}

.projects {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.project-card {
    border: 1px solid var(--light-gray);
    border-radius: 0.5rem;
    overflow: hidden;
    transition: transform 0.3s;
}

.project-card:hover {
    transform: translateY(-5px);
}

.project-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.project-info {
    padding: 1.5rem;
}

.project-info h3 {
    margin-bottom: 0.5rem;
}

/* 커뮤니티 섹션 */
.community {
    background-color: var(--light-gray);
    padding: 4rem 0;
    margin: 4rem 0;
    border-radius: 2rem;
}

.community-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 2rem;
}

.community-links {
    flex: 1;
    min-width: 300px;
}

.link-group h3 {
    margin-bottom: 1rem;
    color: var(--primary);
}

.link-list {
    list-style: none;
}

.link-list li {
    margin-bottom: 0.5rem;
}

.link-list a {
    text-decoration: none;
    color: var(--dark);
    transition: color 0.3s;
    display: flex;
    align-items: center;
}

.link-list a:hover {
    color: var(--primary);
}

/* 푸터 */
footer {
    background-color: var(--footer-bg);
    color: white;
    padding: 3rem 0;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: space-between;
}

.footer-column {
    flex: 1;
    min-width: 200px;
}

.footer-column h3 {
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    text-decoration: none;
    color: #adb5bd;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: white;
}

.copyright {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: #adb5bd;
}

/* 반응형 디자인 */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .theme-menu {
        margin-left: auto;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
}

/* 카드 그리드 레이아웃 */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin: 4rem 0;
}

/* 새로운 콘텐츠 카드 디자인 */
.content-card {
    display: flex;
    flex-direction: column;
    background-color: var(--card-bg);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    height: 100%;
    border: 1px solid var(--card-border);
}

.content-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
}

/* 카드 헤더 스타일 */
.card-header {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--primary) 0%, #2b6cb0 100%);
    color: white;
    font-size: 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.card-icon svg {
    width: 32px;
    height: 32px;
}

/* 카드 본문 스타일 */
.card-body {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-body p {
    margin: 0 0 1rem 0; /* 문단 사이 여백 추가 */
    color: var(--gray);
    line-height: 1.6;
}

.card-body ul {
    list-style-position: inside;
    margin-bottom: 1rem;
    padding-left: 1rem;
}

.card-body li {
    margin-bottom: 0.5rem;
    color: var(--gray);
}

/* 카드 내부 태그 스타일 */
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0;
}

.tag {
    background-color: rgba(26, 79, 114, 0.1);
    color: var(--primary);
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.85rem;
    display: inline-block;
}

body.light-mode .tag {
    background-color: rgba(26, 79, 114, 0.1);
    color: var(--primary);
}

body:not(.light-mode) .tag {
    background-color: rgba(79, 209, 197, 0.15);
    color: #4fd1c5;
}

/* 카드 푸터 스타일 */
.card-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    margin-top: auto;
}

.card-action {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(to right, var(--secondary), #ff9c4a);
    color: white;
    text-decoration: none;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.card-action span {
    flex: 1;
    text-align: center;
}

.card-action i {
    margin-left: 8px;
    transition: transform 0.3s ease;
}

.card-action:hover {
    background: linear-gradient(to right, #e67700, #ff8c2b);
    box-shadow: 0 4px 12px rgba(253, 126, 20, 0.3);
}

.card-action:hover i {
    transform: translateX(4px);
}

.simple-support {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #ffffff;
    padding: 4rem 1rem;
    text-align: center;
    border-radius: 16px;
    margin: 4rem auto;
    max-width: 800px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.support-container {
    max-width: 600px;
    margin: 0 auto;
}

.support-title {
    font-size: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.support-description {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.support-btn {
    font-size: 1.2rem;
    padding: 0.8rem 2rem;
    border-radius: 0.5rem;
    text-decoration: none;
}

/* 다크모드 적용 */
@media (prefers-color-scheme: dark) {
    .content-card {
        background-color: #2d3748;
    }
    
    .card-header {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .card-header h3 {
        color: white;
    }
    
    .card-body p {
        color: #cbd5e0;
    }
    
    .card-footer {
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    /* 다크모드 푸터 스타일 추가 */
    footer {
        background-color: #1a202c;
    }
    
    .footer-content {
        color: #e2e8f0;
    }
    
    .footer-column h3 {
        color: #f7fafc;
    }
    
    .footer-links a {
        color: #a0aec0;
    }
    
    .footer-links a:hover {
        color: #f7fafc;
    }
    
    .copyright {
        color: #a0aec0;
        border-top: 1px solid rgba(255, 255, 255, 0.05);
    }
}