:root {
    --primary-bg: #0f172a;
    --primary-accent: #3b82f6;
    --secondary-accent: #8b5cf6;
}

body {
    background-color: #f8fafc;
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, "Helvetica Neue", "Segoe UI", "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", sans-serif;
    color: #334155;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

.modern-nav {
    background: linear-gradient(135deg, var(--primary-bg) 0%, #1e1b4b 100%) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-logo {
    height: 40px;
    width: auto;
    border-radius: 8px;
    margin-right: 12px;
}

.brand-text {
    font-weight: 800;
    font-size: 1.4rem;
    background: linear-gradient(135deg, var(--primary-accent), var(--secondary-accent));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.5px;
}

.hero-section {
    background: linear-gradient(135deg, var(--primary-bg) 0%, #1e1b4b 100%);
    position: relative;
    padding: 4rem 0 5rem 0;
    overflow: visible !important;
}

.hero-bg-glow {
    position: absolute;
    width: 600px;
    height: 600px;
    background: var(--primary-accent);
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.15;
    top: -200px;
    right: -100px;
    pointer-events: none;
}

.hero-title {
    font-size: 2.8rem;
    font-weight: 800;
    color: white;
    line-height: 1.3;
    letter-spacing: -1px;
    margin-bottom: 1rem;
}

.hero-title span {
    color: #60a5fa;
}

.hero-glass-card {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
    animation: fadeIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.hero-img-showcase {
    width: 100%;
    max-width: 550px;
    border-radius: 20px;
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.6);
    transform: perspective(1000px) rotateY(-5deg) translateY(-10px);
    transition: transform 0.5s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-img-showcase:hover {
    transform: perspective(1000px) rotateY(0deg) translateY(0);
}

.form-label {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

.premium-select {
    background-color: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 12px;
    padding: 0.8rem 1.25rem;
    font-size: 1.05rem;
    font-weight: 500;
    color: #1e293b;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    cursor: pointer;
}

.premium-select:invalid {
    color: #475569 !important;
    font-weight: 600 !important;
}

.premium-select:disabled {
    background-color: rgba(255, 255, 255, 0.85) !important;
    color: #1e293b !important;
    opacity: 1 !important;
    font-weight: 600 !important;
    cursor: not-allowed;
}

.premium-select:focus {
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.3);
    outline: none;
}

.premium-select:disabled {
    background-color: rgba(255, 255, 255, 0.5);
    color: #94a3b8;
    cursor: not-allowed;
}

.content-card {
    background: white;
    border-radius: 24px;
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.05);
    border: 1px solid #f1f5f9;
    overflow: hidden;
    margin-bottom: 2rem;
    position: relative;
    z-index: 10;
}

.category-wrapper {
    margin-bottom: 2rem;
}

.category-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #334155;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

#categoryContainer {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.category-wrapper .form-check {
    margin: 0;
    padding-left: 0;
}

.category-wrapper .form-check-input {
    display: none;
}

.category-wrapper .form-check-label {
    padding: 0.6rem 1.2rem;
    background-color: #f1f5f9;
    color: #64748b;
    border-radius: 9999px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.95rem;
    font-weight: 600;
    border: 1px solid transparent;
}

.category-wrapper .form-check-label:hover {
    background-color: #e2e8f0;
}

.category-wrapper .form-check-input:checked+.form-check-label {
    background-color: var(--primary-accent);
    color: white;
    box-shadow: 0 8px 16px -4px rgba(59, 130, 246, 0.4);
    transform: translateY(-2px);
}

#map {
    width: 100%;
    height: 650px;
    min-height: 650px;
    background-color: #f1f5f9;
}

#tableWrapper {
    min-height: 500px;
    padding: 0.5rem;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.premium-footer {
    background: white;
    border-top: 1px solid #e2e8f0;
    padding: 3rem 0;
    margin-top: 5rem;
    color: #64748b;
}

.kakao-overlay {
    position: relative;
    background-color: #ffffff;
    border-radius: 16px;
    padding: 2.5rem 1.5rem 1.5rem 1.5rem;
    width: 320px;
    max-height: 400px;
    overflow-y: auto;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(0, 0, 0, 0.1);
    z-index: 10000 !important;
}

.kakao-overlay::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 10px 10px 0;
    border-style: solid;
    border-color: #ffffff transparent transparent transparent;
    display: block;
    width: 0;
}

.kakao-overlay .close-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
    color: #64748b;
    z-index: 10;
    background: #f1f5f9;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.kakao-overlay .close-btn:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.facility-block {
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.facility-block:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.facility-title {
    font-weight: 800;
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e2e8f0;
    line-height: 1.4;
}

.highlight-label {
    font-weight: 600;
    color: #475569;
}

/* CSS Overrides for Index Cards */
.card-link {
    text-decoration: none !important;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: transparent;
    padding: 0.5rem;
    position: relative;
    overflow: hidden;
}

.card-link:hover {
    background: linear-gradient(145deg, #ffffff, #f1f5f9);
    box-shadow: 0 10px 25px -5px rgba(59, 130, 246, 0.15);
    transform: translateY(-3px);
}

.card-link img {
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.card-link:hover img {
    transform: scale(1.05);
}

.card-link span {
    color: #475569 !important;
    text-decoration: none !important;
    transition: color 0.3s ease;
}

.card-link:hover span {
    color: #0f172a !important;
}

.card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: 20px;
    box-shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.card-header {
    background: transparent;
    border-bottom: 2px solid #f1f5f9;
    padding: 1.5rem;
}

.card-header p {
    color: #1e293b;
    letter-spacing: -0.5px;
}

.card-body h4 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #3b82f6;
    border: none !important;
    padding-bottom: 0.5rem;
    margin-bottom: 1rem;
    position: relative;
}

.card-body h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6);
    border-radius: 3px;
}

/* Fix dropdown z-index issues when overlapping main content */
.z-10 {
    z-index: 1050 !important;
}
/* Grid.js Global Customizations */
.gridjs-th-content {
    text-overflow: clip !important;
    white-space: nowrap !important;
    overflow: visible !important;
}
.gridjs-th {
    min-width: 80px;
}
button.gridjs-sort {
    display: none !important;
}

/* Fix mobile table squeezing and overlapping globally */
.gridjs-table {
    table-layout: auto !important;
    white-space: nowrap !important;
    min-width: max-content !important;
}


/* Helper for long text in table cells - allow wrap instead of ellipsis */
.table-cell-ellipsis {
    display: inline-block;
    max-width: 100%;
    white-space: normal;
    word-break: keep-all;
    vertical-align: middle;
}

