/* Global Variables */
:root {
    --primary-color: #2c3e50;
    /* Dark Blue/Gray */
    --accent-color: #c0a16b;
    /* Muted Gold */
    --text-color: #333333;
    --light-gray: #f8f9fa;
    --border-color: #e9ecef;
    --white: #ffffff;
    --occupied-bg: #ffffff;
    --vacant-bg: #f1f3f5;
    --vacant-text: #adb5bd;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans KR', sans-serif;
    color: var(--text-color);
    line-height: 1.7;
    background-color: var(--white);
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s;
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 80px 0;
}

/* Header */
header {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: #ffffff; /* 순백색으로 고정하여 로고 배경과 일치시킴 */
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo a {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-logo {
    height: 60px; /* Increased for better readability of text within logo */
    width: auto;
    mix-blend-mode: multiply;
}

#main-nav ul {
    display: flex;
    gap: 30px;
}

#main-nav a {
    font-weight: 500;
    font-size: 1rem;
    color: var(--primary-color);
}

#main-nav a:hover {
    color: var(--accent-color);
}

.mobile-menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
#hero {
    height: 100vh;
    /* Full viewport height */
    position: relative;
    padding: 0;
    overflow: hidden;
}

.hero-slider {
    width: 100%;
    height: 100%;
    position: relative;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-slide.active {
    opacity: 1;
}

.hero-slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    /* Dark overlay */
}

.hero-content {
    position: relative;
    color: var(--white);
    z-index: 1;
    animation: fadeInUp 1s ease-out forwards;
}

.hero-content h2 {
    font-family: 'Playfair Display', serif;
    font-size: 3rem;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-content h2 span {
    font-size: 3.5rem;
    color: var(--accent-color);
}

.hero-content p {
    font-size: 1.2rem;
    opacity: 0.9;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Status Section (Main Feature) */
#status-section {
    background-color: var(--light-gray);
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h3 {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.section-header p {
    color: #666;
}

.section-title-logo {
    height: 80px;
    width: auto;
    vertical-align: middle;
    margin-right: 15px;
    mix-blend-mode: multiply;
}

.status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    /* Responsive Grid */
    gap: 30px;
}

.status-card {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid var(--border-color);
}

.status-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

/* Occupied Status Styles */
.status-card.occupied {
    background: var(--occupied-bg);
}

.status-card.occupied .card-image {
    width: 100%;
    height: 400px;
    position: relative;
    overflow: hidden;
    background-color: #f8f9fa;
    border-bottom: 1px solid var(--border-color);
}

.status-card.occupied .card-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #eee;
}

.status-card.occupied .room-number-tag {
    position: absolute;
    top: 20px;
    left: 20px;
    background-color: var(--primary-color);
    color: var(--white);
    padding: 8px 20px;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.status-card.occupied .card-body {
    padding: 30px;
}

.status-info-row {
    display: flex;
    margin-bottom: 15px;
    align-items: baseline;
}

.status-info-row:last-child {
    margin-bottom: 0;
}

.status-info-row .label {
    width: 100px; /* Increased width for longer labels */
    font-size: 0.95rem;
    color: #777;
    font-weight: 500;
    flex-shrink: 0;
}

.status-info-row .value {
    font-size: 1.05rem;
    font-weight: 500;
    color: var(--text-color);
    line-height: 1.4;
}

.status-info-row .value.name {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.status-info-row .value.highlight {
    color: #c92a2a;
    font-weight: 600;
}

.status-info-row.deceased-row {
    flex-direction: column;
    margin-bottom: 25px;
    border-bottom: 2px solid var(--accent-color);
    padding-bottom: 15px;
}

.status-info-row.deceased-row .label {
    width: auto;
    margin-bottom: 5px;
}

/* Vacant Status Styles */
.status-card.vacant {
    background: var(--vacant-bg);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 250px;
    color: var(--vacant-text);
}

.status-card.vacant .room-number {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: #adb5bd;
}

.status-card.vacant i {
    font-size: 3rem;
    margin-bottom: 10px;
    opacity: 0.5;
}

/* Quick Links / Facilities Section */
.quick-links-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.link-item {
    padding: 35px 20px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    text-align: center;
    background: #fff;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.link-item:hover {
    background-color: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.link-item i {
    font-size: 2.2rem;
    margin-bottom: 15px;
    color: var(--accent-color);
    transition: color 0.3s;
}

.link-item:hover i {
    color: var(--white);
}

.link-item h4 {
    font-family: 'Noto Sans KR', sans-serif;
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.3;
    word-break: keep-all;
    /* 단어 단위로 줄바꿈 */
}

.link-item p {
    font-size: 0.95rem;
    color: #777;
    line-height: 1.6;
    word-break: keep-all;
    margin: 0;
    transition: color 0.3s;
}

.link-item:hover p {
    color: rgba(255, 255, 255, 0.9);
}

/* Funeral Procedures Section */
#process {
    background-color: var(--white);
}

.procedure-tabs {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 50px;
}

.tab-btn {
    padding: 12px 30px;
    border: 1px solid var(--primary-color);
    background: transparent;
    color: var(--primary-color);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: 50px;
    transition: all 0.3s;
}

.tab-btn.active,
.tab-btn:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

.process-day {
    display: none;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.process-day.active {
    display: grid;
    animation: fadeIn 0.5s ease;
}

.process-step {
    display: flex;
    gap: 20px;
    padding: 30px;
    background: var(--light-gray);
    border-radius: 12px;
    border-bottom: 4px solid var(--accent-color);
}

.step-icon {
    width: 40px;
    height: 40px;
    background: var(--primary-color);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: 700;
    flex-shrink: 0;
}

.step-info h4 {
    color: var(--primary-color);
    margin-bottom: 10px;
}

.step-info p {
    font-size: 0.95rem;
    color: #666;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Location Section */
.map-container {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    margin-bottom: 40px;
}

.map-overlay-btn {
    position: absolute;
    bottom: 20px;
    right: 20px;
    z-index: 10;
}

.btn {
    display: inline-block;
    padding: 12px 24px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 6px;
    font-weight: 500;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s;
}

.btn:hover {
    background-color: var(--accent-color);
    transform: translateY(-2px);
}

.info-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.info-box {
    padding: 25px;
    background-color: var(--white);
    border-radius: 8px;
    border-left: 5px solid var(--accent-color);
    box-shadow: var(--shadow-sm);
}

.info-box h4 {
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.info-box h4 i {
    margin-right: 10px;
}

footer {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 60px 0;
}

.footer-container {
    display: flex;
    align-items: center;
    gap: 40px;
}

.footer-logo-img {
    height: 225px;
    width: auto;
    mix-blend-mode: screen;
    filter: invert(1) contrast(300%) sepia(1) saturate(20) hue-rotate(15deg) brightness(1.7);
}

.footer-info h3 {
    margin-bottom: 10px;
}

.footer-info h3 {
    margin-bottom: 0;
}



/* Convenience Section */
#convenience {
    background-color: var(--white);
    padding: 80px 0;
}

.convenience-tabs {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 50px;
}

.conv-tab-btn {
    padding: 12px 40px;
    background: #f8f9fa;
    border: 1px solid var(--border-color);
    border-radius: 30px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s;
}

.conv-tab-btn.active {
    background: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-sm);
}

.convenience-content {
    display: none;
    animation: fadeIn 0.5s ease;
}

.convenience-content.active {
    display: block;
}

/* Food Grid */
.food-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.food-item {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s;
}

.food-item:hover {
    transform: translateY(-5px);
}

.food-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.food-item h4 {
    padding: 20px 20px 10px;
    color: var(--primary-color);
    font-size: 1.25rem;
}

.food-item p {
    padding: 0 20px 25px;
    color: #666;
    line-height: 1.6;
}

/* Facility Grid */
.facility-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.facility-card {
    background: #fdfdfd;
    padding: 35px 25px;
    border-radius: 12px;
    text-align: center;
    border: 1px solid #f1f1f1;
    transition: all 0.3s;
}

.facility-card:hover {
    background: var(--white);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

.facility-card i {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 20px;
}

.facility-card h4 {
    margin-bottom: 12px;
    color: var(--primary-color);
}

.facility-card p {
    font-size: 0.95rem;
    color: #777;
    line-height: 1.5;
}

/* Responsive Extensions */
@media (max-width: 992px) {

    .food-grid,
    .facility-grid,
    .quick-links-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {

    .food-grid,
    .facility-grid {
        grid-template-columns: 1fr;
    }

    .conv-tab-btn {
        padding: 10px 25px;
        font-size: 1rem;
    }
}


/* FAQ Section */
#faq {
    background-color: var(--light-gray);
    padding: 80px 0;
}

.faq-container {
    max-width: 800px;
    margin: 30px auto 0;
}

.faq-item {
    background: var(--white);
    border-radius: 8px;
    margin-bottom: 15px;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: all 0.3s;
}

.faq-question {
    padding: 22px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-weight: 500;
    color: var(--primary-color);
    transition: background 0.3s;
}

.faq-question:hover {
    background: #fcfcfc;
}

.faq-question i {
    transition: transform 0.3s;
    color: var(--accent-color);
    font-size: 0.9rem;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 30px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-in-out;
    background: #fff;
    border-top: 1px solid transparent;
}

.faq-item.active .faq-answer {
    padding: 25px 30px;
    max-height: 500px;
    border-top: 1px solid var(--border-color);
}

.faq-answer p {
    color: #666;
    line-height: 1.8;
    margin: 0;
}

/* Responsive Customization for FAQ */
@media (max-width: 768px) {
    .faq-question {
        padding: 18px 20px;
        font-size: 0.95rem;
    }
}

/* Floating Actions (Mobile & Scroll to Top) */
.floating-actions {
    position: fixed;
    bottom: 30px;
    right: 30px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 999;
}

.scroll-top-btn,
.mobile-call-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.scroll-top-btn {
    background-color: var(--white);
    color: var(--primary-color);
    visibility: hidden;
    opacity: 0;
    transform: translateY(20px);
}

.scroll-top-btn.show {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
}

.mobile-call-btn {
    background-color: var(--accent-color);
    color: var(--white);
    text-decoration: none;
    display: none;
    /* Hidden by default on PC */
}

.scroll-top-btn:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* Base Responsive */
@media (max-width: 1200px) {
    .container {
        max-width: 95%;
    }
}

/* PC Version High-end Tweaks (1024px and above) */
@media (min-width: 1024px) {
    .container {
        max-width: 1140px;
    }

    .status-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .hero-content h2 {
        font-size: 4rem;
    }
}

/* Mobile Version Optimization (768px and below) */
@media (max-width: 768px) {
    #main-header {
        height: 70px;
    }

    .mobile-call-btn {
        display: flex;
        /* Show only on mobile */
    }

    .mobile-menu-toggle {
        display: block;
    }

    header .container {
        padding: 0 20px;
    }

    #main-nav {
        display: none;
        position: absolute;
        top: 70px;
        left: 0;
        width: 100%;
        background: var(--white);
        box-shadow: var(--shadow-md);
        z-index: 1000;
    }

    #main-nav.active {
        display: block;
    }

    #main-nav ul {
        flex-direction: column;
        padding: 20px;
        gap: 0;
    }

    #main-nav ul li a {
        padding: 18px 0;
        border-bottom: 1px solid #eee;
        display: block;
        width: 100%;
        font-size: 1.1rem;
    }

    .hero-content h2 {
        font-size: 2.4rem;
        letter-spacing: -1px;
    }

    .hero-content h2 span {
        font-size: 3rem;
    }

    .hero-content p {
        font-size: 1.1rem;
        line-height: 1.7;
    }

    .status-grid,
    .quick-links-grid,
    .info-details,
    .food-grid,
    .facility-grid {
        grid-template-columns: 1fr !important;
        gap: 20px;
    }

    .process-day {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .section-header h3 {
        font-size: 2.2rem;
        margin-bottom: 15px;
    }

    .section-header p {
        font-size: 1.05rem;
        line-height: 1.6;
    }

    .tab-btn,
    .conv-tab-btn {
        padding: 14px 25px;
        font-size: 1.05rem;
        min-width: 100px;
    }

    .faq-question {
        padding: 20px;
        font-size: 1.05rem;
        line-height: 1.4;
    }

    .faq-answer p {
        font-size: 1rem;
        line-height: 1.7;
    }

    #faq .faq-container {
        padding: 0 5px;
    }
}

/* Smaller Mobile Optimization (480px and below) */
@media (max-width: 480px) {
    .hero-content h2 {
        font-size: 2rem;
    }

    .hero-content h2 span {
        font-size: 2.4rem;
    }

    .hero-content p {
        font-size: 1.05rem;
    }

    .floating-actions {
        bottom: 20px;
        right: 20px;
    }

    .scroll-top-btn,
    .mobile-call-btn {
        width: 45px;
        height: 45px;
    }
}