/* Design Tokens & Theme Setup */
:root {
    /* Color Palette */
    --primary-color: #555e90;
    --primary-light: #7b84b5;
    --primary-dark: #3b4369;
    --secondary-color: #cda96b;
    --secondary-light: #dfc18d;
    --secondary-dark: #a88346;
    --point-color: #ea659b;
    --point-light: #ef8db7;
    --point-dark: #c54277;
    
    /* Backgrounds & Text */
    --bg-color: #f7f9fc;
    --bg-gradient: linear-gradient(135deg, #f7f9fc 0%, #edf1f7 100%);
    --card-bg: #ffffff;
    --text-color: #2e3142;
    --text-muted: #6e738f;
    --white: #ffffff;
    
    /* Status Colors */
    --color-meeting: #555e90;
    --color-workshop: #cda96b;
    --color-volunteer: #ea659b;
    --color-festival: #5bc0be;
    
    /* Borders & Shadows */
    --border-color: #e4e7eb;
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 10px 15px -3px rgba(85, 94, 144, 0.08), 0 4px 6px -2px rgba(85, 94, 144, 0.04);
    --shadow-lg: 0 20px 25px -5px rgba(85, 94, 144, 0.12), 0 10px 10px -5px rgba(85, 94, 144, 0.06);
    --shadow-hover: 0 25px 50px -12px rgba(85, 94, 144, 0.2);
    
    /* Borders & Border Radius */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    
    /* Animation & Transitions */
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-smooth);
}

button, input, textarea, select {
    font-family: inherit;
    border: none;
    outline: none;
}

button {
    cursor: pointer;
    background: none;
}

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

/* Typography Helpers */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-subtitle {
    font-family: 'Outfit', sans-serif;
    color: var(--secondary-dark);
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    display: inline-block;
    margin-bottom: 0.5rem;
}

.section-title {
    font-size: 2.2rem;
    color: var(--primary-dark);
    font-weight: 800;
    margin-bottom: 1rem;
}

.title-underline {
    width: 50px;
    height: 4px;
    background-color: var(--point-color);
    margin: 0 auto 1.5rem auto;
    border-radius: var(--radius-full);
}

.section-desc {
    max-width: 650px;
    margin: 0 auto;
    color: var(--text-muted);
    font-size: 1.1rem;
}

/* Button Component Styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem 1.8rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    transition: var(--transition-smooth);
    box-shadow: var(--shadow-sm);
}

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

.btn-primary:hover {
    background-color: var(--point-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background-color: var(--white);
    color: var(--primary-color);
    border: 2px solid var(--primary-light);
}

.btn-secondary:hover {
    background-color: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-cta {
    background-color: var(--secondary-color);
    color: var(--primary-dark);
    font-weight: 700;
}

.btn-cta:hover {
    background-color: var(--secondary-light);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(205, 169, 107, 0.3);
}

/* Header & Sticky Navigation */
#main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(85, 94, 144, 0.08);
    transition: var(--transition-smooth);
}

#main-header.scrolled {
    padding: 0.5rem 0;
    box-shadow: var(--shadow-md);
    background-color: rgba(255, 255, 255, 0.95);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.2rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition-smooth);
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--primary-dark);
}

.logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    border-radius: var(--radius-sm);
    font-size: 1.1rem;
}

.logo-text span {
    color: var(--secondary-color);
    font-weight: 700;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-color);
    position: relative;
    padding: 0.3rem 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--point-color);
    transition: var(--transition-smooth);
}

.nav-link:hover {
    color: var(--point-color);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link.active {
    color: var(--point-color);
}

.btn-header-signup {
    background-color: var(--primary-color);
    color: var(--white) !important;
    padding: 0.5rem 1.2rem;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-sm);
}

.btn-header-signup::after {
    display: none;
}

.btn-header-signup:hover {
    background-color: var(--point-color);
    color: var(--white) !important;
    transform: translateY(-1px);
}

/* Hamburger & Mobile Nav Menu */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 6px;
    width: 30px;
    z-index: 1001;
}

.hamburger .bar {
    width: 100%;
    height: 3px;
    background-color: var(--primary-dark);
    border-radius: var(--radius-full);
    transition: var(--transition-smooth);
}

.hamburger.active .bar:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.hamburger.active .bar:nth-child(2) {
    opacity: 0;
}

.hamburger.active .bar:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

.mobile-nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 75%;
    height: 100vh;
    background-color: var(--white);
    z-index: 999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.05);
    transition: var(--transition-smooth);
}

.mobile-nav.active {
    right: 0;
}

.mobile-link {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.mobile-link:hover {
    color: var(--point-color);
}

.mobile-btn-signup {
    background-color: var(--point-color);
    color: var(--white);
    padding: 0.7rem 2rem;
    border-radius: var(--radius-md);
}

/* Hero Section */
#hero {
    position: relative;
    padding: 10rem 0 6rem 0;
    background: var(--bg-gradient);
    min-height: 80vh;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('images/main_hero.png');
    background-size: cover;
    background-position: center bottom; /* 하단의 인물과 현수막이 가려지지 않도록 정렬하고 상단의 하늘 여백을 크롭 */
    opacity: 0.18; /* 불투명도를 18%로 조절하여 텍스트 가독성과 조화를 이룸 */
    z-index: 1;
    pointer-events: none;
}

#hero::before {
    content: '';
    position: absolute;
    top: -10%;
    right: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, rgba(205, 169, 107, 0.1) 0%, rgba(255, 255, 255, 0) 70%);
    border-radius: var(--radius-full);
    z-index: 1;
}

#hero::after {
    content: '';
    position: absolute;
    bottom: -20%;
    left: -10%;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(85, 94, 144, 0.08) 0%, rgba(255, 255, 255, 0) 70%);
    border-radius: var(--radius-full);
    z-index: 1;
}

.hero-container {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.hero-content {
    max-width: 600px;
}

.hero-badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    background-color: rgba(85, 94, 144, 0.1);
    color: var(--primary-dark);
    font-size: 0.85rem;
    font-weight: 700;
    border-radius: var(--radius-full);
    margin-bottom: 1.5rem;
    border: 1px solid rgba(85, 94, 144, 0.15);
}

.hero-title {
    font-size: 3.5rem;
    line-height: 1.2;
    color: var(--primary-dark);
    font-weight: 900;
    margin-bottom: 1.5rem;
}

.hero-title span {
    color: var(--point-color);
    background: linear-gradient(135deg, var(--point-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-desc {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    line-height: 1.7;
    word-break: keep-all;
    overflow-wrap: break-word;
}

.hero-actions {
    display: flex;
    gap: 1rem;
}

.hero-visual {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 380px;
}

.visual-card-wrapper {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    width: 100%;
    height: 100%;
}

.visual-card {
    position: relative;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: var(--radius-md);
    padding: 1.8rem 1rem;
    box-shadow: var(--shadow-lg);
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 165px;
    height: 240px; /* 카드 3개의 세로 높이를 240px로 고정하여 완전히 동일한 크기로 일치시킴 */
    text-align: center;
    animation: floatAnim 6s ease-in-out infinite alternate;
}

.visual-card i {
    font-size: 2.2rem;
    margin-bottom: 1rem;
}

.visual-card h4 {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--primary-dark);
    margin-bottom: 0.3rem;
}

.visual-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
    word-break: keep-all; /* 한글 단어(어절)가 음절 단위로 끊겨서 줄바꿈되지 않도록 방지 */
}

.card-1 {
    background-color: rgba(255, 255, 255, 0.95);
    border-top: 4px solid var(--primary-color);
    animation-delay: 0s;
}

.card-1 i {
    color: var(--primary-color);
}

.card-2 {
    background-color: rgba(255, 255, 255, 0.95);
    border-top: 4px solid var(--secondary-color);
    animation-delay: 1.5s;
}

.card-2 i {
    color: var(--secondary-color);
}

.card-3 {
    background-color: rgba(255, 255, 255, 0.95);
    border-top: 4px solid var(--point-color);
    animation-delay: 3s;
}

.card-3 i {
    color: var(--point-color);
}

.visual-card:hover {
    transform: scale(1.05) translateY(-5px);
    z-index: 10;
    box-shadow: var(--shadow-hover);
}

@keyframes floatAnim {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(-15px);
    }
}

/* About Us Section */
#about {
    padding: 6rem 0;
    background-color: var(--white);
}

/* Brand Identity Showcase Box */
.brand-identity-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3.5rem;
    background-color: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 2.5rem 3.5rem;
    max-width: 800px;
    margin: 3.5rem auto 0 auto;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
    flex-wrap: wrap;
}

.brand-identity-box:hover {
    box-shadow: var(--shadow-md);
    border-color: rgba(205, 169, 107, 0.2);
    transform: translateY(-2px);
}

.brand-logo-preview {
    flex: 1;
    min-width: 320px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-right: 1px solid var(--border-color);
    padding-right: 3rem;
}

.brand-logo-img {
    max-height: 160px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.05));
    transition: var(--transition-smooth);
}

.brand-logo-img:hover {
    transform: scale(1.05);
}

.brand-colors {
    flex: 1.5;
    min-width: 280px;
    text-align: left;
}

.brand-colors h4 {
    font-size: 1rem;
    font-weight: 800;
    color: var(--primary-dark);
    margin-bottom: 1.2rem;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.brand-colors h4 i {
    color: var(--secondary-color);
}

.color-palette {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.color-chip-wrapper {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.color-chip {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08), 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: var(--transition-smooth);
}

.color-chip-wrapper:hover .color-chip {
    transform: scale(1.1) rotate(5deg);
}

.color-code {
    font-family: 'Outfit', sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--primary-dark);
    display: flex;
    align-items: center;
}

@media (max-width: 768px) {
    .brand-identity-box {
        gap: 2rem;
        padding: 2rem;
        flex-direction: column;
    }
    .brand-logo-preview {
        border-right: none;
        padding-right: 0;
        border-bottom: 1px solid var(--border-color);
        padding-bottom: 1.5rem;
        width: 100%;
    }
    .brand-colors {
        width: 100%;
        text-align: center;
    }
    .brand-colors h4 {
        justify-content: center;
    }
    .color-palette {
        align-items: center;
    }
}

.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
    margin-top: 2rem;
}

.about-card {
    background-color: var(--bg-color);
    border-radius: var(--radius-md);
    padding: 3rem 2rem;
    position: relative;
    overflow: hidden;
    transition: var(--transition-smooth);
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.card-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 70px;
    height: 70px;
    background-color: rgba(85, 94, 144, 0.08);
    border-radius: var(--radius-md);
    transition: var(--transition-smooth);
}

.about-card h3 {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

.about-card p {
    color: var(--text-muted);
    font-size: 1rem;
}

.card-border {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--secondary-color) 50%, var(--point-color) 100%);
    transition: var(--transition-smooth);
}

.about-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    background-color: var(--white);
    border-color: rgba(205, 169, 107, 0.3);
}

.about-card:hover .card-icon {
    background-color: var(--primary-color);
    color: var(--white);
    transform: rotateY(360deg);
}

.about-card:hover .card-border {
    width: 100%;
}

.about-card-subtitle {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--secondary-dark);
    margin-bottom: 0.8rem;
}

.card-hashtags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1.5rem;
}

.hashtag {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--primary-light);
    background-color: rgba(85, 94, 144, 0.05);
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-sm);
    transition: var(--transition-smooth);
}

.about-card:hover .hashtag {
    background-color: rgba(234, 101, 155, 0.08);
    color: var(--point-color);
}

/* History Section Timeline */
#history {
    padding: 6rem 0;
    background-color: var(--white);
    border-top: 1px solid var(--border-color);
}

.history-timeline {
    max-width: 800px;
    margin: 3rem auto 0 auto;
    position: relative;
    padding-left: 3.5rem;
}

.history-item {
    position: relative;
    margin-bottom: 3rem;
}

.history-item:last-child {
    margin-bottom: 0;
}

/* Dynamic gradient connector line between badges */
.history-item::before {
    content: '';
    position: absolute;
    left: -2.25rem;
    top: 22px;
    bottom: calc(-3rem - 22px);
    width: 4px;
    z-index: 1;
    border-radius: var(--radius-full);
}

.history-item:last-child::before {
    display: none;
}

/* Gradients from each badge's color to the next */
.history-item:nth-child(1)::before {
    background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
}
.history-item:nth-child(2)::before {
    background: linear-gradient(to bottom, var(--secondary-color), var(--point-color));
}
.history-item:nth-child(3)::before {
    background: linear-gradient(to bottom, var(--point-color), #5bc0be);
}
.history-item:nth-child(4)::before {
    background: linear-gradient(to bottom, #5bc0be, #3a86c8);
}
.history-item:nth-child(5)::before {
    background: linear-gradient(to bottom, #3a86c8, var(--primary-color));
}

.history-badge {
    position: absolute;
    left: -3.5rem;
    top: 0;
    width: 44px;
    height: 44px;
    border-radius: var(--radius-full);
    background-color: var(--white);
    border: 3px solid var(--primary-color);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    z-index: 2;
    transition: var(--transition-smooth);
    box-shadow: var(--shadow-sm);
}

.history-item:nth-child(2) .history-badge { border-color: var(--secondary-color); color: var(--secondary-color); }
.history-item:nth-child(3) .history-badge { border-color: var(--point-color); color: var(--point-color); }
.history-item:nth-child(4) .history-badge { border-color: #5bc0be; color: #5bc0be; }
.history-item:nth-child(5) .history-badge { border-color: #3a86c8; color: #3a86c8; }

.history-content {
    background-color: var(--bg-color);
    padding: 2rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    transition: var(--transition-smooth);
}

.history-content h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 0.8rem;
}

.history-content p {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.7;
}

.history-item:hover .history-badge {
    transform: scale(1.1);
    box-shadow: var(--shadow-md);
}

.history-item:hover .history-content {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    background-color: var(--white);
    border-color: rgba(205, 169, 107, 0.2);
}

/* Gallery Section */
#gallery {
    padding: 6rem 0;
    background-color: var(--bg-color);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 1.5rem;
}

.gallery-item {
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    background-color: var(--white);
    transition: var(--transition-smooth);
}

.gallery-img-box {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
}

.gallery-img-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(59, 67, 105, 0.95) 0%, rgba(59, 67, 105, 0.7) 60%, rgba(255,255,255,0) 100%);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    opacity: 0;
    transition: var(--transition-smooth);
    color: var(--white);
}

.gallery-tag {
    display: inline-block;
    padding: 0.2rem 0.8rem;
    background-color: var(--secondary-color);
    color: var(--primary-dark);
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: var(--radius-full);
    width: fit-content;
    margin-bottom: 0.8rem;
}

.gallery-overlay h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    transform: translateY(15px);
    transition: var(--transition-smooth);
}

.gallery-overlay p {
    font-size: 0.9rem;
    opacity: 0.85;
    line-height: 1.5;
    transform: translateY(20px);
    transition: var(--transition-smooth);
    transition-delay: 0.05s;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-item:hover .gallery-overlay h3,
.gallery-item:hover .gallery-overlay p {
    transform: translateY(0);
}

/* Calendar Section */
#calendar-section {
    padding: 6rem 0;
    background-color: var(--white);
}

.calendar-wrapper {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
    margin-top: 1rem;
}

/* Calendar Sidebar (Moved to Bottom) */
.calendar-sidebar {
    background-color: var(--bg-color);
    border-radius: var(--radius-md);
    padding: 2rem;
    border: 1px solid var(--border-color);
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    align-items: start;
}

.upcoming-box h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 1.2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.upcoming-box h3 i {
    color: var(--secondary-color);
}

.upcoming-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.upcoming-item {
    background-color: var(--white);
    border-radius: var(--radius-sm);
    padding: 1rem;
    border-left: 4px solid var(--primary-color);
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    transition: var(--transition-smooth);
}

.upcoming-item:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow-md);
}

.upcoming-item.meeting { border-left-color: var(--color-meeting); }
.upcoming-item.workshop { border-left-color: var(--color-workshop); }
.upcoming-item.volunteer { border-left-color: var(--color-volunteer); }
.upcoming-item.festival { border-left-color: var(--color-festival); }

.upcoming-date {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 0.3rem;
}

.upcoming-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.calendar-legend h4 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 0.9rem;
    margin-bottom: 0.6rem;
    color: var(--text-muted);
    font-weight: 500;
}

.legend-item .dot {
    width: 12px;
    height: 12px;
    border-radius: var(--radius-full);
}

.legend-meeting { background-color: var(--color-meeting); }
.legend-workshop { background-color: var(--color-workshop); }
.legend-volunteer { background-color: var(--color-volunteer); }
.legend-festival { background-color: var(--color-festival); }

/* Main Calendar Area */
.calendar-main {
    background-color: var(--white);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.calendar-header-controls {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.calendar-nav {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.cal-btn {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-full);
    background-color: var(--bg-color);
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}

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

.cal-btn-text {
    padding: 0.4rem 1rem;
    background-color: var(--bg-color);
    color: var(--primary-dark);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    transition: var(--transition-smooth);
}

.cal-btn-text:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

.current-date-title {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--primary-dark);
    min-width: 130px;
    text-align: center;
}

.view-toggle {
    display: flex;
    background-color: var(--bg-color);
    padding: 0.3rem;
    border-radius: var(--radius-sm);
}

.toggle-btn {
    padding: 0.4rem 1.2rem;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    transition: var(--transition-smooth);
}

.toggle-btn.active {
    background-color: var(--white);
    color: var(--primary-dark);
    box-shadow: var(--shadow-sm);
}

.calendar-body {
    padding: 1.5rem;
}

.calendar-view.hide {
    display: none;
}

/* Monthly Grid */
.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-weight: 700;
    color: var(--text-muted);
    font-size: 0.9rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.weekday.sun { color: var(--point-color); }
.weekday.sat { color: #4b89dc; }

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    grid-auto-rows: minmax(110px, auto);
}

.day-cell {
    border-right: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    padding: 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    transition: var(--transition-smooth);
    background-color: var(--white);
}

.day-cell:nth-child(7n) { border-right: none; }

.day-cell.other-month {
    background-color: #fcfdfe;
    color: #cbd5e1;
}

.day-cell.today {
    background-color: rgba(205, 169, 107, 0.05);
}

.day-cell.today .day-number {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-full);
    background-color: var(--secondary-color);
    color: var(--primary-dark);
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.day-number {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.day-cell.sunday .day-number { color: var(--point-color); }
.day-cell.saturday .day-number { color: #4b89dc; }

.day-cell.other-month .day-number {
    color: #cbd5e1 !important;
}

.day-events {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.cal-event-bar {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    color: var(--white);
    
    /* Allow text wrapping up to 3 lines with ellipsis */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    white-space: normal;
    word-break: keep-all;
    overflow-wrap: break-word;
    overflow: hidden;
    text-overflow: ellipsis;
    
    cursor: pointer;
    transition: var(--transition-smooth);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.cal-event-bar:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
    filter: brightness(1.05);
}

.cal-event-bar.meeting { background-color: var(--color-meeting); }
.cal-event-bar.workshop { background-color: var(--color-workshop); color: var(--primary-dark); }
.cal-event-bar.volunteer { background-color: var(--color-volunteer); }
.cal-event-bar.festival { background-color: var(--color-festival); color: var(--primary-dark); }

/* Other month calendar event bar opacity */
.day-cell.other-month .cal-event-bar {
    opacity: 0.55;
    transition: opacity 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.day-cell.other-month .cal-event-bar:hover {
    opacity: 1;
}

/* Weekly View styles */
#weekly-weekdays {
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1rem;
}

.weekly-day-title {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
}

.weekly-day-title span.day-num {
    font-size: 1.2rem;
    font-weight: 800;
}

.weekly-day-title.today span.day-num {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    background-color: var(--secondary-color);
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    justify-content: center;
}

.weekly-time-grid {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.weekly-event-card {
    background-color: var(--bg-color);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    border-left: 6px solid var(--primary-color);
    box-shadow: var(--shadow-sm);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition-smooth);
    cursor: pointer;
}

.weekly-event-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    background-color: var(--white);
}

.weekly-event-card.meeting { border-left-color: var(--color-meeting); }
.weekly-event-card.workshop { border-left-color: var(--color-workshop); }
.weekly-event-card.volunteer { border-left-color: var(--color-volunteer); }
.weekly-event-card.festival { border-left-color: var(--color-festival); }

.weekly-event-info {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.weekly-event-time {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--point-color);
}

.weekly-event-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.weekly-event-location {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.weekly-event-location i {
    margin-right: 0.3rem;
}

.weekly-event-btn {
    padding: 0.5rem 1rem;
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--primary-color);
    transition: var(--transition-smooth);
}

.weekly-event-card:hover .weekly-event-btn {
    background-color: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
}

.weekly-empty-message {
    text-align: center;
    padding: 3rem 0;
    color: var(--text-muted);
    font-size: 1.05rem;
    font-weight: 500;
}

/* Call to Action Section */
#cta {
    position: relative;
    padding: 8rem 0;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    color: var(--white);
    text-align: center;
    overflow: hidden;
}

#cta::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -20%;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(234, 101, 155, 0.15) 0%, rgba(0, 0, 0, 0) 75%);
    z-index: 1;
}

.cta-container {
    position: relative;
    z-index: 2;
    max-width: 800px;
}

#cta h2 {
    font-size: 2.6rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.3;
}

#cta p {
    font-size: 1.15rem;
    opacity: 0.85;
    margin-bottom: 3rem;
    line-height: 1.8;
}

/* Footer Section */
footer {
    background-color: #1f2233;
    color: #a3a8cc;
    padding: 5rem 0 2rem 0;
    font-size: 0.95rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-container {
    display: grid;
    grid-template-columns: 1.5fr 0.8fr 1.2fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-about .logo {
    color: var(--white);
    margin-bottom: 1.5rem;
    display: inline-flex;
    align-items: center;
}

.footer-logo-img {
    height: 48px;
    width: auto;
    object-fit: contain;
    transition: var(--transition-smooth);
}

.footer-logo-img:hover {
    transform: scale(1.03);
}

.footer-about p {
    line-height: 1.7;
    margin-bottom: 1.8rem;
    font-size: 0.9rem;
}

.footer-socials {
    display: flex;
    gap: 1rem;
}

.footer-socials a {
    width: 38px;
    height: 38px;
    border-radius: var(--radius-full);
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
    transition: var(--transition-smooth);
}

.footer-socials a:hover {
    background-color: var(--point-color);
    transform: translateY(-3px);
}

.footer-links h3,
.footer-contact h3 {
    color: var(--white);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    position: relative;
}

.footer-links h3::after,
.footer-contact h3::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 30px;
    height: 2px;
    background-color: var(--secondary-color);
}

.footer-links ul,
.footer-contact ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.footer-links a:hover {
    color: var(--white);
    padding-left: 5px;
}

.footer-contact li {
    display: flex;
    gap: 0.8rem;
    align-items: flex-start;
}

.footer-contact i {
    color: var(--secondary-color);
    margin-top: 0.2rem;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.85rem;
}

.footer-bottom i {
    color: var(--point-color);
    margin: 0 0.2rem;
}

/* Modals Overlay (Common) */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(31, 34, 51, 0.65);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
    padding: 1rem;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background-color: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 650px;
    padding: 3rem;
    position: relative;
    transform: translateY(30px);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    max-height: 90vh;
    overflow-y: auto;
}

.modal-overlay.active .modal-content {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    font-size: 2rem;
    font-weight: 300;
    color: var(--text-muted);
    transition: var(--transition-smooth);
}

.modal-close:hover {
    color: var(--point-color);
    transform: rotate(90deg);
}

/* Signup Modal Specific */
.modal-header {
    margin-bottom: 2rem;
    text-align: center;
}

.modal-header h2 {
    font-size: 1.8rem;
    color: var(--primary-dark);
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.modal-header p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.2rem;
}

.form-group {
    margin-bottom: 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.form-group .required {
    color: var(--point-color);
}

.form-group input,
.form-group textarea {
    padding: 0.8rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
    background-color: var(--bg-color);
    color: var(--text-color);
    transition: var(--transition-smooth);
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary-color);
    background-color: var(--white);
    box-shadow: 0 0 0 3px rgba(85, 94, 144, 0.15);
}

.form-group textarea {
    resize: none;
}

.form-group small {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.form-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.form-checkbox input {
    width: 18px;
    height: 18px;
    accent-color: var(--point-color);
}

.form-checkbox label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-color);
}

.btn-submit {
    width: 100%;
    background-color: var(--primary-color);
    color: var(--white);
    padding: 1rem;
    font-size: 1.05rem;
    font-weight: 700;
}

.btn-submit:hover {
    background-color: var(--point-color);
}

/* Success Modal Specific */
.success-content {
    max-width: 480px;
    text-align: center;
    padding: 3.5rem 2.5rem;
}

.success-icon {
    font-size: 4rem;
    color: #2ec4b6;
    margin-bottom: 1.5rem;
    animation: scaleUp 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes scaleUp {
    0% { transform: scale(0.5); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

.success-content h2 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--primary-dark);
    margin-bottom: 1rem;
}

.success-content p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 0.8rem;
}

.welcome-text {
    font-weight: 700;
    color: var(--point-color) !important;
    font-size: 1.05rem !important;
    margin: 1.5rem 0 2rem 0 !important;
}

/* Event Detail Modal Specific */
.event-modal-content {
    max-width: 500px;
}

.event-modal-header {
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1.2rem;
    margin-bottom: 1.5rem;
}

.event-tag {
    display: inline-block;
    padding: 0.2rem 0.8rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 0.6rem;
    background-color: var(--primary-color);
}

.event-tag.meeting { background-color: var(--color-meeting); }
.event-tag.workshop { background-color: var(--color-workshop); color: var(--primary-dark); }
.event-tag.volunteer { background-color: var(--color-volunteer); }
.event-tag.festival { background-color: var(--color-festival); color: var(--primary-dark); }

.event-modal-header h2 {
    font-size: 1.5rem;
    color: var(--primary-dark);
    font-weight: 800;
}

.event-modal-body {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.info-row {
    display: flex;
    align-items: center;
    font-size: 0.95rem;
}

.info-label {
    width: 80px;
    font-weight: 700;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.info-label i {
    width: 16px;
    text-align: center;
}

.info-value {
    color: var(--primary-dark);
    font-weight: 600;
}

.event-desc-box {
    margin-top: 0.8rem;
    padding: 1.2rem;
    background-color: var(--bg-color);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.event-desc-box h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.event-desc-box p {
    font-size: 0.9rem;
    color: var(--text-color);
    line-height: 1.6;
}

.event-modal-footer {
    margin-top: 2rem;
    display: flex;
    justify-content: flex-end;
}

/* Responsive Styles */
@media (max-width: 992px) {
    .hero-container {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }
    
    .hero-content {
        margin: 0 auto;
    }
    
    .hero-title {
        font-size: 2.8rem;
    }
    
    .hero-actions {
        justify-content: center;
    }
    
    .hero-visual {
        height: auto;
        margin-top: 2rem;
    }
    
    .visual-card-wrapper {
        display: flex;
        justify-content: center;
        gap: 1.5rem;
        flex-wrap: wrap;
        height: auto;
    }
    
    .visual-card {
        position: relative;
        top: auto !important;
        left: auto !important;
        right: auto !important;
        bottom: auto !important;
        width: 190px;
        margin: 0;
        animation: floatAnimMobile 6s ease-in-out infinite alternate;
    }
    
    @keyframes floatAnimMobile {
        0% { transform: translateY(0); }
        100% { transform: translateY(-8px); }
    }
    
    .calendar-wrapper {
        grid-template-columns: 1fr;
    }
    
    .calendar-sidebar {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: space-between;
    }
    
    .upcoming-box, .calendar-legend {
        flex: 1;
        min-width: 280px;
    }
    
    .footer-container {
        grid-template-columns: 1.2fr 0.8fr;
        gap: 3rem;
    }
    
    .footer-contact {
        grid-column: span 2;
    }
}

@media (max-width: 768px) {
    html {
        font-size: 15px;
    }
    
    .nav-menu {
        display: none;
    }
    
    .hamburger {
        display: flex;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .about-grid, .gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .footer-container {
        grid-template-columns: 1fr;
    }
    
    .footer-contact {
        grid-column: span 1;
    }
    
    .modal-content {
        padding: 2.5rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2.2rem;
    }
    
    .hero-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .hero-actions .btn {
        width: 100%;
    }
    
    .visual-card {
        width: 100%;
        max-width: 280px;
        height: auto; /* 모바일 세로 적층 시에는 콘텐츠 길이에 맞게 높이를 자동 조절 */
        padding: 1.5rem 1.2rem;
    }
    
    .visual-card i {
        font-size: 2rem;
        margin-bottom: 0.6rem;
    }
    
    .visual-card h4 {
        font-size: 1.25rem;
    }
    
    .calendar-days {
        grid-auto-rows: minmax(80px, auto);
    }
    
    .day-cell {
        padding: 0.3rem;
    }
    
    .day-number {
        font-size: 0.8rem;
    }
    
    .cal-event-bar {
        font-size: 0.65rem;
        padding: 0.1rem 0.2rem;
    }
}

/* Auth & Admin Header buttons */
.btn-header-login {
    background-color: transparent !important;
    color: var(--primary-color) !important;
    border: 1px solid var(--primary-light) !important;
    padding: 0.5rem 1.2rem;
    border-radius: var(--radius-sm);
    display: inline-flex;
    align-items: center;
}
.btn-header-login:hover {
    background-color: var(--primary-color) !important;
    color: var(--white) !important;
    transform: translateY(-1px);
}
.btn-header-admin {
    background-color: var(--secondary-color) !important;
    color: var(--primary-dark) !important;
    padding: 0.5rem 1.2rem;
    border-radius: var(--radius-sm);
    font-weight: 700;
}
.btn-header-admin:hover {
    background-color: var(--secondary-light) !important;
    transform: translateY(-1px);
}

.hide {
    display: none !important;
}

/* Login Modal Specifics */
.login-modal-content {
    max-width: 420px;
}
.admin-credentials-hint {
    background-color: rgba(85, 94, 144, 0.05);
    border-left: 4px solid var(--secondary-color);
    padding: 0.8rem 1rem;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin: 0.5rem 0 1.5rem 0;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    line-height: 1.5;
}
.admin-credentials-hint strong {
    color: var(--primary-dark);
}

/* Admin Dashboard Specifics */
.admin-modal-content {
    max-width: 1400px;
    width: 95%;
    max-height: 95vh;
    padding: 2.5rem 2rem;
}
.admin-modal-header {
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1.2rem;
}
.admin-modal-header h2 {
    font-size: 1.8rem;
    color: var(--primary-dark);
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}
.admin-modal-header h2 i {
    color: var(--secondary-color);
}
.admin-modal-header p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.admin-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}
.admin-stat-card {
    background-color: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.2rem 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}
.stat-title {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
}
.stat-value {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--primary-dark);
}

.admin-controls {
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: flex-end;
}
.admin-controls .search-box {
    position: relative;
    width: 300px;
}
.admin-controls .search-box i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}
.admin-controls .search-box input {
    width: 100%;
    padding: 0.7rem 1rem 0.7rem 2.5rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    background-color: var(--bg-color);
    transition: var(--transition-smooth);
}
.admin-controls .search-box input:focus {
    background-color: var(--white);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(85, 94, 144, 0.15);
}

/* Members Table Grid */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    background-color: var(--white);
}
.members-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.9rem;
    min-width: 750px;
}
.members-table th {
    background-color: #f1f5f9;
    color: var(--primary-dark);
    font-weight: 700;
    padding: 1rem;
    border-bottom: 2px solid var(--border-color);
    word-break: keep-all;
    overflow-wrap: break-word;
    white-space: normal;
    line-height: 1.4;
}
.members-table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-color);
    vertical-align: middle;
    word-break: keep-all;
    overflow-wrap: break-word;
    white-space: normal;
    line-height: 1.4;
}

/* Table Column Width Constraints for Optimal Readability */
.members-table th:nth-child(1), .members-table td:nth-child(1) { min-width: 95px; } /* 이름, 생일 */
.members-table th:nth-child(2), .members-table td:nth-child(2) { min-width: 120px; max-width: 140px; } /* 학교/학번 */
.members-table th:nth-child(3), .members-table td:nth-child(3) { min-width: 110px; } /* 연락처 */
.members-table th:nth-child(4), .members-table td:nth-child(4) { min-width: 180px; max-width: 230px; } /* 주소 */
.members-table th:nth-child(5), .members-table td:nth-child(5) { min-width: 110px; max-width: 130px; } /* 납부정보 */
.members-table th:nth-child(6), .members-table td:nth-child(6) { min-width: 160px; max-width: 220px; } /* 계좌정보 */
.members-table th:nth-child(7), .members-table td:nth-child(7) { min-width: 90px; } /* 신청일 */
.members-table th:nth-child(8), .members-table td:nth-child(8) { min-width: 90px; } /* 상태 */
.members-table th:nth-child(9), .members-table td:nth-child(9) { min-width: 60px; text-align: center; } /* 후원 */
.members-table th:nth-child(10), .members-table td:nth-child(10) { min-width: 110px; } /* 관리 */
.members-table tbody tr:last-child td {
    border-bottom: none;
}
.members-table tbody tr:hover {
    background-color: rgba(85, 94, 144, 0.02);
}

/* Status Badges */
.badge-status {
    display: inline-block;
    padding: 0.25rem 0.6rem;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: var(--radius-full);
}
.badge-pending {
    background-color: #fef3c7;
    color: #d97706;
}
.badge-approved {
    background-color: #d1fae5;
    color: #059669;
}

/* Table Management Buttons */
.btn-table-approve {
    background-color: #10b981;
    color: var(--white);
    padding: 0.35rem 0.7rem;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: var(--radius-sm);
    margin-right: 0.4rem;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
}
.btn-table-approve:hover {
    background-color: #059669;
    transform: translateY(-1px);
}
.btn-table-delete {
    background-color: #ef4444;
    color: var(--white);
    padding: 0.35rem 0.7rem;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
}
.btn-table-delete:hover {
    background-color: #dc2626;
    transform: translateY(-1px);
}
.table-empty-msg {
    text-align: center;
    padding: 3rem !important;
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 600;
}

@media (max-width: 768px) {
    .admin-stats-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .admin-controls .search-box {
        width: 100%;
    }
}

/* Header Calligraphy Logo */
.logo-header {
    display: flex;
    align-items: center;
}

.header-logo-img {
    height: 52px;
    width: auto;
    object-fit: contain;
    transition: var(--transition-smooth);
}

.header-logo-img:hover {
    transform: scale(1.03);
}

/* Custom Form Notice & Checkboxes */
.form-notice-text {
    font-size: 0.8rem;
    color: var(--point-dark);
    margin-top: 0.3rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    line-height: 1.4;
    font-weight: 500;
}

.border-box-input {
    border: 1px dashed var(--point-light);
    padding: 1.2rem;
    border-radius: var(--radius-sm);
    background-color: rgba(234, 101, 155, 0.02);
}

.form-checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin-bottom: 2rem;
}

.form-checkbox-group .form-checkbox {
    margin-bottom: 0 !important;
}

/* FlipClock Widget Styles */
.clock-box {
    background-color: var(--white);
    border-radius: var(--radius-md);
    padding: 1.5rem 1rem;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    text-align: center;
    transition: var(--transition-smooth);
}

.clock-box:hover {
    box-shadow: var(--shadow-md);
    border-color: rgba(85, 94, 144, 0.15);
}

.clock-box h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.clock-box h3 i {
    color: var(--point-color);
}

.flip-clock {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}

.flip-unit {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.flip-card-wrapper {
    position: relative;
    width: 60px;
    height: 60px;
    background-color: #2e3142; /* Dark slate */
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
    perspective: 200px;
}

.flip-card-half {
    position: absolute;
    left: 0;
    width: 100%;
    height: 50%;
    overflow: hidden;
    display: flex;
    justify-content: center;
    color: #ffffff;
    background-color: #2e3142;
    font-family: 'Outfit', sans-serif;
    font-size: 2.2rem;
    font-weight: 700;
    line-height: 1;
}

.flip-card-half.top,
.flip-card-half.top-flip {
    top: 0;
    align-items: flex-end;
    border-top-left-radius: var(--radius-sm);
    border-top-right-radius: var(--radius-sm);
    border-bottom: 0.5px solid rgba(0, 0, 0, 0.4);
}

.flip-card-half.top span,
.flip-card-half.top-flip span {
    transform: translateY(50%);
}

.flip-card-half.bottom,
.flip-card-half.bottom-flip {
    bottom: 0;
    align-items: flex-start;
    border-bottom-left-radius: var(--radius-sm);
    border-bottom-right-radius: var(--radius-sm);
    border-top: 0.5px solid rgba(0, 0, 0, 0.4);
}

.flip-card-half.bottom span,
.flip-card-half.bottom-flip span {
    transform: translateY(-50%);
}

/* 3D Flip Transitions */
.flip-card-half.top-flip {
    transform-origin: bottom;
    z-index: 3;
}

.flip-card-half.bottom-flip {
    transform-origin: top;
    transform: rotateX(90deg);
    z-index: 2;
}

.flip-colon {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1.2rem;
    animation: blink 1s infinite;
}

.flip-label {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

/* Flip animations classes */
.flip-card-wrapper.flipping .top-flip {
    animation: flip-top 0.6s ease-in forwards;
}

.flip-card-wrapper.flipping .bottom-flip {
    animation: flip-bottom 0.6s ease-out forwards;
    animation-delay: 0.3s;
}

@keyframes flip-top {
    0% { transform: rotateX(0deg); }
    100% { transform: rotateX(-90deg); }
}

@keyframes flip-bottom {
    0% { transform: rotateX(90deg); }
    100% { transform: rotateX(0deg); }
}

/* Organization Modal Custom Styles */
.org-modal-content {
    max-width: 850px;
    width: 90%;
}

.org-modal-header-desc {
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1.2rem;
}

.org-modal-header-desc h2 {
    font-size: 1.6rem;
    color: var(--primary-dark);
    font-weight: 800;
}

.org-modal-header-desc p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-top: 0.3rem;
}

.org-tabs {
    display: flex;
    justify-content: center;
    border-bottom: 2px solid var(--border-color);
    margin-bottom: 2rem;
    gap: 1rem;
}

.org-tab-btn {
    padding: 0.8rem 1.2rem;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-muted);
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    transition: var(--transition-smooth);
}

.org-tab-btn:hover {
    color: var(--primary-color);
}

.org-tab-btn.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.org-tab-content {
    min-height: 350px;
}

.org-tree-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 1.5rem 0 3rem 0;
}

.node-box {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.2rem 1.5rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 300px;
    text-align: center;
    transition: var(--transition-smooth);
}

.node-box:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.node-name {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin: 0.4rem 0 0.6rem 0;
    background-color: var(--bg-color);
    padding: 0.25rem 0.9rem;
    border-radius: var(--radius-full);
    display: inline-block;
    border: 1px solid rgba(85, 94, 144, 0.08);
}

.node-box i {
    font-size: 1.8rem;
    margin-bottom: 0.6rem;
}

.node-box h4 {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--primary-dark);
    margin-bottom: 0.3rem;
}

.node-box p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* Node Border Accent Colors (Nationwide Tree) */
.main-org { border-top: 4px solid var(--primary-color); }
.main-org i { color: var(--primary-color); }

.branch-org { border-top: 4px solid var(--secondary-color); }
.branch-org i { color: var(--secondary-color); }

.chapter-org { border-top: 4px solid #5bc0be; }
.chapter-org i { color: #5bc0be; }

.sub-org { border-top: 4px solid var(--point-color); }
.sub-org i { color: var(--point-color); }

/* Steering Committee Differentiated Color Theme */
/* 1. Joint Representatives (Leader / Pink Accent) */
.leader-box { 
    border-top: 4px solid var(--point-color); 
}
.leader-box i { 
    color: var(--point-color); 
}
.leader-box .node-name {
    color: var(--point-dark);
    background-color: rgba(234, 101, 155, 0.08);
    border-color: rgba(234, 101, 155, 0.15);
}

/* 2. Steering Committee Chairs (Execution / Slate Blue Accent) */
.exec-box, .poli-box, .ext-box, .policy-box, .edu-box { 
    border-top: 4px solid var(--primary-color); 
}
.exec-box i, .poli-box i, .ext-box i, .policy-box i, .edu-box i { 
    color: var(--primary-color); 
}
.exec-box .node-name, .poli-box .node-name, .ext-box .node-name, .policy-box .node-name, .edu-box .node-name {
    color: var(--primary-dark);
    background-color: rgba(85, 94, 144, 0.08);
    border-color: rgba(85, 94, 144, 0.15);
}

.org-tree-connector {
    width: 3px;
    height: 25px;
    background-color: var(--border-color);
}

.org-explanations {
    background-color: rgba(85, 94, 144, 0.03);
    border-left: 4px solid var(--primary-color);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    padding: 1.5rem 1.8rem;
    text-align: left;
    margin-top: 2rem;
}

.org-explanations h4 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.org-explanations ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.org-explanations li {
    font-size: 0.9rem;
    color: var(--text-color);
    margin-bottom: 0.6rem;
    line-height: 1.5;
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
}

.org-explanations li:last-child {
    margin-bottom: 0;
}

.org-explanations li i {
    font-size: 0.5rem;
    color: var(--secondary-color);
}

.org-explanations li strong {
    color: var(--primary-dark);
}

/* Committee Layout */
.committee-layout {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 1.5rem 0;
}

.committee-leader {
    margin-bottom: 0.2rem;
}

.committee-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    width: 100%;
    margin-top: 0.2rem;
}

.committee-member {
    display: flex;
}

.committee-member .node-box {
    width: 100%;
    padding: 1.5rem 1rem;
}

.org-modal-footer {
    border-top: 1px solid var(--border-color);
    padding-top: 1.2rem;
    margin-top: 2rem;
    display: flex;
    justify-content: flex-end;
}

@media (max-width: 768px) {
    .org-tabs {
        flex-direction: row;
        justify-content: center;
        gap: 0.5rem;
        border-bottom: 2px solid var(--border-color);
        margin-bottom: 1.5rem;
    }
    .org-tab-btn {
        width: auto;
        font-size: 0.85rem;
        padding: 0.6rem 0.8rem;
        border-bottom: 3px solid transparent;
        border-left: none;
        background-color: transparent;
        border-radius: 0;
        margin-bottom: -2px;
    }
    .org-tab-btn.active {
        border-bottom-color: var(--primary-color);
        border-left-color: transparent;
        background-color: transparent;
        color: var(--primary-color);
    }
    .calendar-header-controls {
        justify-content: center;
        gap: 1.2rem;
    }
    .calendar-nav {
        width: 100%;
        justify-content: center;
    }
    .view-toggle {
        margin: 0 auto;
    }
    .node-box {
        width: 100%;
        max-width: 300px;
    }
}

/* Monthly Summary Section (Calendar Bottom) */
.monthly-summary-section {
    margin-top: 4rem;
    padding: 3rem 2rem;
    background-color: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
    transition: var(--transition-smooth);
}

.monthly-summary-section.hide {
    display: none;
}

.summary-title-wrapper {
    text-align: center;
    margin-bottom: 2.5rem;
}

.summary-title-wrapper h3 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.summary-title-underline {
    width: 40px;
    height: 3px;
    background-color: var(--secondary-color);
    margin: 0 auto;
    border-radius: var(--radius-full);
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.summary-card {
    background-color: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.8rem;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    position: relative;
    overflow: hidden;
}

.summary-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background-color: var(--primary-color);
}

/* Card Accent Colors */
.summary-card:nth-child(2n)::before { background-color: var(--secondary-color); }
.summary-card:nth-child(3n)::before { background-color: var(--point-color); }
.summary-card:nth-child(4n)::before { background-color: #5bc0be; }

.summary-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    background-color: var(--white);
    border-color: rgba(205, 169, 107, 0.2);
}

.summary-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.5rem;
}

.summary-card-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--primary-dark);
    line-height: 1.3;
}

.summary-card-date {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--point-color);
    background-color: rgba(234, 101, 155, 0.05);
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-sm);
    width: fit-content;
    white-space: nowrap;
}

.summary-card:nth-child(2n) .summary-card-date {
    color: var(--secondary-dark);
    background-color: rgba(205, 169, 107, 0.08);
}

.summary-card-desc {
    font-size: 0.92rem;
    color: var(--text-muted);
    line-height: 1.6;
    font-weight: 500;
}

/* Terms Agreement Styles */
.form-checkbox-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.form-checkbox-row .form-checkbox {
    margin-bottom: 0;
}

.btn-view-terms {
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: underline;
    cursor: pointer;
    transition: var(--transition-smooth);
    padding: 0.2rem 0.5rem;
    border-radius: var(--radius-sm);
    white-space: nowrap;
}

.btn-view-terms:hover {
    color: var(--point-color);
    background-color: rgba(234, 101, 155, 0.05);
}

.form-checkbox input:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.form-checkbox input:disabled + label {
    color: var(--text-muted);
    cursor: not-allowed;
}

.terms-body p {
    margin-bottom: 1rem;
}

.terms-body p:last-child {
    margin-bottom: 0;
}

/* Member-only Event card style */
.member-only-card {
    border-left: 4px dashed var(--point-color) !important;
    background-color: rgba(234, 101, 155, 0.02) !important;
}

/* 회칙 모달 전용 스타일 */
.rules-modal-content {
    max-width: 950px;
    width: 95%;
    max-height: 85vh;
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
}

.rules-modal-header {
    margin-bottom: 1.5rem;
    flex-shrink: 0;
}

.rules-container {
    display: flex;
    gap: 1.5rem;
    flex: 1;
    overflow: hidden; /* 모달 내 자체 스크롤 */
    min-height: 0; /* flex-grow가 정상 동작하도록 설정 */
}

/* 좌측 탭 리스트 */
.rules-sidebar {
    width: 220px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    overflow-y: auto;
    padding-right: 0.5rem;
    border-right: 1px solid var(--border-color);
}

.rules-tab-btn {
    width: 100%;
    padding: 0.9rem 1.2rem;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-muted);
    background: none;
    border: none;
    border-radius: var(--radius-sm);
    text-align: left;
    cursor: pointer;
    transition: var(--transition-smooth);
    border-left: 3px solid transparent;
}

.rules-tab-btn:hover {
    background-color: var(--bg-light);
    color: var(--primary-color);
}

.rules-tab-btn.active {
    background-color: rgba(85, 94, 144, 0.08); /* primary-color인 #555e90의 투명도 */
    color: var(--primary-color);
    border-left: 3px solid var(--primary-color);
}

/* 우측 상세 보기 (종이/독스 스타일) */
.rules-content-wrapper {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
    background-color: #f6f8fa; /* 구글 독스 바깥 배경 느낌 */
    border-radius: var(--radius-sm);
}

.rules-paper {
    background-color: var(--white);
    box-shadow: 0 1px 3px rgba(0,0,0,0.05), 0 1px 2px rgba(0,0,0,0.1);
    border-radius: var(--radius-sm);
    padding: 2.5rem;
    min-height: 100%;
}

.rules-pane {
    display: none;
}

.rules-pane.active {
    display: block;
}

.rules-pane h3 {
    font-size: 1.4rem;
    color: var(--primary-dark);
    font-weight: 800;
    margin-bottom: 0.8rem;
    margin-top: 0;
}

.rules-divider {
    border: 0;
    height: 1px;
    background-color: var(--border-color);
    margin-bottom: 1.5rem;
}

.rules-article {
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.rules-article h4 {
    font-size: 1.05rem;
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 0.4rem;
}

.rules-article p {
    color: var(--text-color);
    font-size: 0.95rem;
    margin: 0;
}

.rules-nested-box {
    background-color: var(--bg-light);
    padding: 1.2rem;
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--point-color);
    margin-top: 0.8rem;
}

.rules-nested-box h5 {
    font-size: 0.95rem;
    color: var(--primary-dark);
    font-weight: 700;
    margin-bottom: 0.6rem;
    margin-top: 0;
}

.rules-nested-box ol {
    margin: 0;
    padding-left: 1.2rem;
}

.rules-nested-box li {
    font-size: 0.9rem;
    color: var(--text-color);
    margin-bottom: 0.4rem;
    line-height: 1.6;
}

.rules-modal-footer {
    margin-top: 1.5rem;
    display: flex;
    justify-content: flex-end;
    flex-shrink: 0;
}

/* 반응형 모바일 레이아웃 */
@media (max-width: 768px) {
    .rules-modal-content {
        padding: 1.5rem;
        height: 90vh;
    }
    
    .rules-container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .rules-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
        flex-direction: row;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 0.5rem;
        padding-right: 0;
        white-space: nowrap;
        gap: 0.5rem;
        height: auto;
    }
    
    .rules-tab-btn {
        width: auto;
        padding: 0.6rem 1rem;
        border-left: none;
        border-bottom: 3px solid transparent;
        display: inline-block;
    }
    
    .rules-tab-btn.active {
        border-left: none;
        border-bottom: 3px solid var(--primary-color);
        background-color: transparent;
    }
    
    .rules-content-wrapper {
        padding: 0.5rem;
    }
    
    .rules-paper {
        padding: 1.5rem;
    }
}
