:root {
    /* Color Palette */
    --primary-color: #1B3022;
    --primary-light: #2D4F39;
    --secondary-color: #D9E4DD;
    --accent-color: #D4AF37;
    --text-dark: #1A1A1A;
    --text-muted: #555555;
    --bg-light: #F9FBFA;
    --bg-white: #FFFFFF;

    /* Typography */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Spacing & Borders */
    --container-max-width: 1200px;
    --section-padding: 70px 0;
    --border-radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

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

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

body {
    font-family: var(--font-body);
    font-size: 1rem;
    color: var(--text-dark);
    line-height: 1.6;
    background-color: var(--bg-white);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4 {
    font-family: var(--font-heading);
    line-height: 1.2;
}

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

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 0 24px;
}

.section-padding {
    padding: var(--section-padding);
}

.text-center {
    text-align: center;
}

.bg-light {
    background-color: var(--bg-light);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 14px 32px;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    border: none;
    font-family: var(--font-heading);
}

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

.btn-primary:hover {
    background-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(27, 48, 34, 0.2);
}

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

.btn-secondary:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

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

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

.btn-outline-primary {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

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

.btn-text {
    padding: 0;
    color: var(--primary-color);
    background: none;
}

.btn-text:hover {
    color: var(--accent-color);
}

/* Header & Nav */
#main-header {
    position: relative;
    width: 100%;
    z-index: 1000;
    transition: var(--transition);
    padding: 20px 0;
    background: var(--bg-white);
    /* Ensure background is solid */
}

#main-header.scrolled {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    padding: 15px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

#main-header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    /* gap: 30px; */
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    /* 20px */
    font-weight: 700;
    letter-spacing: 1px;
    margin-right: 30px; /* 로고와 메뉴 사이 간격 조절 */
}

.logo span {
    color: var(--accent-color);
    font-weight: 400;
    margin-left: 5px;
}

.nav-links {
    display: flex;
    gap: 40px;
}

.nav-links a {
    font-size: 1.0rem;
    /* 15px */
    font-weight: 500;
}

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

#main-header.scrolled .nav-links a {
    color: var(--text-dark);
}

/* Header Util */
.header-util {
    font-size: 0.8rem;
    margin-left: auto;
    margin-right: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-util a {
    color: #777;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 5px;
}

.header-util a:hover {
    color: var(--accent-color);
}

.header-util i {
    font-size: 0.9rem;
}

.header-util .admin-name {
    color: #999;
    font-size: 0.75rem;
}

/* 드롭다운 메뉴 스타일 */
.nav-links .has-dropdown {
    position: relative;
}

.nav-links .dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-white);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 10px 0;
    min-width: 150px;
    display: none;
    z-index: 1000;
}

.nav-links .dropdown-menu li {
    width: 100%;
}

.nav-links .dropdown-menu a {
    display: block;
    padding: 10px 20px;
    font-size: 0.9rem;
    color: var(--text-dark);
    text-align: center;
    white-space: nowrap;
}

.nav-links .dropdown-menu a:hover {
    background-color: var(--bg-light);
    color: var(--accent-color);
}

.nav-links .has-dropdown:hover .dropdown-menu {
    display: block;
    animation: fadeInDown 0.3s ease-out;
}

/* 가로형 드롭다운 메뉴 (샘플 2) */
.nav-links .has-horizontal-dropdown {
    position: relative;
}

.nav-links .horizontal-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-white);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 10px 15px;
    display: flex; /* 가로 정렬 */
    gap: 5px;
    display: none; /* 기본 숨김 */
    z-index: 1000;
}

.nav-links .horizontal-dropdown-menu li {
    white-space: nowrap;
}

.nav-links .horizontal-dropdown-menu a {
    display: block;
    padding: 8px 15px;
    font-size: 0.9rem;
    color: var(--text-dark);
    border-radius: 4px;
    text-align: center;
}

.nav-links .horizontal-dropdown-menu a:hover {
    background-color: var(--bg-light);
    color: var(--accent-color);
}

.nav-links .has-horizontal-dropdown:hover .horizontal-dropdown-menu {
    display: flex; /* 마우스 오버 시 flex로 노출 */
    animation: fadeInDown 0.3s ease-out;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translate(-50%, -10px);
    }
    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

/* Mobile Menu Toggle */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 26px;
    height: 18px;
    cursor: pointer;
    z-index: 1001;
    position: relative;
}

.mobile-menu-btn span {
    display: block;
    height: 2px;
    width: 100%;
    background-color: var(--primary-color);
    border-radius: 10px;
    transition: var(--transition);
}

/* Hamburger to X Animation */
.mobile-menu-btn.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
    transform: translateX(-20px);
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Hero Section */
#hero {
    height: 70vh;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)), url('images/hero.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    color: white;
    position: relative;
}

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

.hero-content h1 {
    font-size: 4.5rem;
    margin-bottom: 24px;
    font-weight: 700;
}

.hero-content p {
    font-size: 1.25rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

.hero-btns {
    display: flex;
    gap: 15px;
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
}

.scroll-indicator span {
    display: block;
    width: 2px;
    height: 60px;
    background: rgba(255, 255, 255, 0.3);
    position: relative;
    overflow: hidden;
}

.scroll-indicator span::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    animation: scroll-line 2s infinite;
}

@keyframes scroll-line {
    0% {
        transform: translateY(-100%);
    }

    100% {
        transform: translateY(100%);
    }
}

/* Section Headers */
.section-header {
    margin-bottom: 35px;
}

.subtitle {
    display: block;
    font-size: 1.5rem;
    /* 14px */
    font-weight: 700;
    color: var(--accent-color);
    letter-spacing: 2px;
    margin-bottom: 8px;
}

.section-header h2 {
    font-size: 2.5rem;
    /* 40px */
    color: var(--primary-color);
}

.page-header {
    text-align: center;
    margin-bottom: 10px;
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.about-text p {
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: var(--text-muted);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 40px;
}

.stat-item {
    text-align: center;
}

.stat-num {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    font-family: var(--font-heading);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.about-image .image-wrapper {
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.1);
}

.about-image img {
    transition: var(--transition);
}

.about-image:hover img {
    transform: scale(1.05);
}

/* Product Section */
.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.product-card {
    background: var(--bg-white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.product-card:hover {
    transform: translateY(-10px);
}

.product-img {
    height: 300px;
    overflow: hidden;
    position: relative;
}

.product-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-img img {
    transform: scale(1.1);
}

.badge {
    position: absolute;
    top: 20px;
    left: 20px;
    background: var(--accent-color);
    color: var(--primary-color);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 700;
}

.product-info {
    padding: 30px;
}

.product-info h3 {
    margin-bottom: 12px;
    font-size: 1.5rem;
}

.product-info p {
    color: var(--text-muted);
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.price {
    display: block;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 15px;
}

/* Quality Banner */
.quality-banner {
    background: var(--primary-color);
    color: white;
    padding: 80px;
    border-radius: var(--border-radius);
    text-align: center;
}

.quality-banner h2 {
    margin-bottom: 50px;
    font-size: 2rem;
}

.quality-items {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.icon {
    font-size: 3rem;
    margin-bottom: 20px;
}

.q-item h4 {
    margin-bottom: 12px;
    font-size: 1.2rem;
}

.q-item p {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Contact Section */
.contact-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    background: var(--bg-white);
    padding: 60px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.contact-info h2 {
    margin-bottom: 20px;
}

.contact-list {
    margin-top: 30px;
}

.contact-list li {
    margin-bottom: 15px;
}

.contact-form {
    display: block;
    width: 100%;
}

.contact-form .form-group {
    margin-bottom: 20px;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #E0E0E0;
    border-radius: 8px;
    font-family: var(--font-body);
}

.full-width {
    width: 100%;
}

.w-xs {
    max-width: 100px !important;
}

.w-sm {
    max-width: 200px !important;
}

.w-md {
    max-width: 350px !important;
}

.w-lg {
    max-width: 600px !important;
}

.flex-group {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.flex-group>* {
    flex: 1;
    min-width: 150px;
}


/* Footer */
footer {
    background: #111;
    color: white;
    padding: 60px 0;
}

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

.footer-info h3 {
    margin-bottom: 8px;
    font-family: var(--font-heading);
}

.footer-address {
    margin-bottom: 6px;
    font-size: 0.95rem;
    opacity: 0.85;
    display: flex;
    align-items: center;
    gap: 6px;
}

.footer-address i {
    color: var(--accent-color);
}

.footer-contact {
    margin-bottom: 8px;
    font-size: 0.95rem;
    opacity: 0.85;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.footer-contact a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

.footer-contact a:hover {
    color: var(--accent-color);
}

.footer-contact .divider {
    opacity: 0.4;
}

.footer-contact i {
    color: var(--accent-color);
    margin-right: 4px;
}

.footer-copy {
    font-size: 0.875rem;
    opacity: 0.6;
}

.footer-links a {
    margin-left: 30px;
    font-size: 14px;
    opacity: 0.7;
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

.footer-links a:hover {
    opacity: 1;
    color: var(--accent-color);
}

/* Responsive */
@media (max-width: 992px) {
    .hero-content h1 {
        font-size: 3.5rem;
    }

    .about-grid,
    .product-grid,
    .contact-card {
        grid-template-columns: 1fr;
    }

    .quality-items {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 65%;
        /* 60% might be too narrow on some phones, 65% is safer */
        height: 100vh;
        background: var(--primary-color);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 30px;
        transition: 0.4s cubic-bezier(0.77, 0.2, 0.05, 1.0);
        z-index: 1000;
        padding: 40px;
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.2);
    }

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

    .nav-links a {
        font-size: 1.25rem;
        font-weight: 500;
        font-family: var(--font-heading);
        color: rgba(255, 255, 255, 0.8);
    }

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

    .nav-links .cart-link a {
        color: var(--accent-color);
    }

    /* Overlay when menu is open */
    .nav-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        opacity: 0;
        visibility: hidden;
        transition: var(--transition);
        z-index: 999;
        backdrop-filter: blur(3px);
    }

    .nav-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    .mobile-menu-btn.active span {
        background-color: white;
        /* Make hamburger white when menu is open on dark background */
    }

    .nav-cta {
        display: none;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .section-padding {
        padding: 60px 0;
    }

    .quality-banner {
        padding: 40px 20px;
    }

    .footer-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .footer-links a {
        margin-left: 0;
        margin-right: 20px;
    }
}

/* Toast Notification */
#toast-container {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
}

.toast {
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 12px 24px;
    border-radius: 50px;
    font-size: 14px;
    margin-bottom: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    animation: slideUpFadeIn 0.3s ease-out forwards;
}

@keyframes slideUpFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.toast.fade-out {
    animation: slideDownFadeOut 0.3s ease-in forwards;
}

@keyframes slideDownFadeOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }

    to {
        opacity: 0;
        transform: translateY(20px);
    }
}

/* Board Common */
.board-container {
    max-width: 1000px;
    margin: 10px auto 60px;
    background: var(--bg-white);
    padding: 10px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.board-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.board-table th {
    background: var(--bg-light);
    color: var(--primary-color);
    padding: 18px 15px;
    font-family: var(--font-heading);
    font-weight: 600;
    border-bottom: 2px solid var(--primary-color);
}

.board-table td {
    padding: 12px 9px;
    border-bottom: 1px solid #eee;
    text-align: center;
}

.board-table .title {
    text-align: left;
    font-weight: 500;
}

.board-table tr:hover td {
    background: #fcfcfc;
    color: var(--accent-color);
    cursor: pointer;
}

.board-view-header {
    border-bottom: 1px solid #eee;
    padding-bottom: 25px;
    margin-bottom: 35px;
    text-align: center;
}

.board-view-header h3 {
    font-size: 2rem;
    /* 32px */
    color: var(--primary-color);
    margin-bottom: 15px;
}

.board-meta {
    font-size: 0.875rem;
    /* 14px */
    color: var(--text-muted);
}

.board-meta span {
    margin-right: 20px;
}

.board-content {
    line-height: 1.8;
    min-height: 300px;
    color: #444;
    white-space: pre-wrap;
    font-size: 1.0625rem;
    /* 17px */
}

/* Crops Content */
.crops-content {
    white-space: normal;
}

.content-table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    font-size: 0.95rem;
}

.content-table th, 
.content-table td {
    border: 1px solid #E0E0E0;
    padding: 12px 15px;
}

.content-table th {
    background-color: var(--bg-light);
    color: var(--primary-color);
    font-weight: 600;
    text-align: center;
}

.content-table td {
    text-align: left;
}

.content-table tr:nth-child(even) {
    background-color: #F9FBFA;
}

@media (max-width: 768px) {
    .board-container {
        padding: 30px 20px;
        margin-top: 100px;
    }

    .board-table th:nth-child(1),
    .board-table td:nth-child(1) {
        display: none;
    }

    .board-table th:nth-child(4),
    .board-table td:nth-child(4) {
        display: none;
    }
}

.notice-link:hover {
    color: var(--primary-color) !important;
    transform: translateX(5px);
}

.floating-btns {
    position: fixed;
    bottom: 30px;
    right: 30px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 1000;
}

.floating-btn {
    width: 55px;
    height: 55px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.kakao-btn {
    background-color: #FEE500;
    color: #3C1E1E;
}

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

.floating-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.lookup-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 40px;
}

@media (max-width: 768px) {
    .lookup-grid {
        grid-template-columns: 1fr;
    }
}

/* Product Detail Tabs */
.tabs {
    display: flex;
    border-bottom: 1px solid #ddd;
    margin-top: 40px;
    background: #fff;
    position: relative;
    z-index: 100;
}

.tab-link {
    flex: 1;
    padding: 15px 20px;
    text-align: center;
    cursor: pointer;
    font-weight: 600;
    font-family: var(--font-heading);
    color: var(--text-muted);
    border-bottom: 3px solid transparent;
    transition: var(--transition);
}

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

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

.tab-content {
    display: none;
    padding: 40px 0;
}

.tab-content.active {
    display: block;
}

/* Review & Inquiry Cards */
.review-item,
.inquiry-item {
    padding: 20px;
    border-bottom: 1px solid #eee;
}

.review-header,
.inquiry-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.rating {
    color: var(--accent-color);
}

.author {
    font-weight: 600;
    font-size: 0.9rem;
}

.date {
    color: #999;
    font-size: 0.8rem;
}

.empty-msg {
    text-align: center;
    padding: 40px;
    color: #999;
}

.policy-content {
    background: var(--bg-light);
    padding: 30px;
    border-radius: var(--border-radius);
    font-size: 0.95rem;
}

.policy-content h4 {
    margin: 20px 0 10px;
    color: var(--primary-color);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 40px;
    margin-bottom: 40px;
}

.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 6px;
    border-radius: 8px;
    border: 1px solid #E0E0E0;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-dark);
    text-decoration: none;
    transition: var(--transition);
}

.pagination a:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background-color: var(--bg-light);
}

.pagination .active {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.pagination .disabled {
    color: #CCC;
    pointer-events: none;
    background-color: #F5F5F5;
}

/* Board Form */
.board-form-container {
    background: var(--bg-white);
    padding: 10px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-top: 10px;
    margin-bottom: 60px;
}

.board-form .form-group {
    margin-bottom: 25px;
}

.board-form label {
    display: block;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.board-form input[type="text"],
.board-form input[type="email"],
.board-form input[type="password"],
.board-form input[type="date"],
.board-form input[type="number"],
.board-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #E0E0E0;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition);
}

.board-form input[type="text"]:focus,
.board-form input[type="email"]:focus,
.board-form input[type="password"]:focus,
.board-form input[type="date"]:focus,
.board-form input[type="number"]:focus,
.board-form textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(44, 62, 80, 0.1);
}

.board-form textarea {
    min-height: 400px;
    resize: vertical;
}

.board-form .btn-area {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 40px;
}

/* 검색 영역 */
.search-area {
    margin-bottom: 20px;
    display: flex;
    justify-content: flex-end;
}

.search-area form {
    display: flex;
    gap: 8px;
}

.search-area select {
    padding: 10px 15px;
    border-radius: 8px;
    border: 1px solid #E0E0E0;
    font-family: var(--font-body);
    font-size: 0.95rem;
    background-color: #fff;
    color: var(--text-dark);
    outline: none;
    cursor: pointer;
}

.search-area select:focus,
.search-area input[type="text"]:focus {
    border-color: var(--primary-color);
}

.search-area input[type="text"] {
    padding: 10px 15px;
    border-radius: 8px;
    border: 1px solid #E0E0E0;
    width: 250px;
    font-family: var(--font-body);
    font-size: 0.95rem;
}

.search-area button {
    padding: 10px 25px;
    border-radius: 8px;
    font-size: 0.95rem;
}

/* 목록 페이지 버튼 영역 */
.list-btn-area {
    text-align: right;
    margin-top: 20px;
    margin-bottom: 20px;
}

.list-btn-area .btn {
    padding: 10px 25px;
    border-radius: 8px;
}

/* 상세/폼 페이지 버튼 영역 */
.board-btn-area {
    margin-top: 60px;
    text-align: center;
    border-top: 1px solid #eee;
    padding-top: 40px;
    display: flex;
    justify-content: center;
    gap: 15px;
}

.board-btn-area .btn {
    padding: 12px 40px;
}

/* 폼 페이지 버튼 영역 */
.form-btn-area {
    margin-top: 40px;
    text-align: center;
    display: flex;
    justify-content: center;
    gap: 15px;
}

.form-btn-area .btn {
    padding: 12px 40px;
}


/* ==========================================================================
   Global Mobile App Mode & Subpage Responsive Styles
   ========================================================================== */

/* 기본적으로 PC에서는 모바일 전용 컴포넌트 숨김 */
.m-common-header,
.m-common-footer,
.m-bottom-nav,
.m-drawer,
.m-drawer-overlay,
.m-status-badge {
    display: none;
}

/* 모바일 모드 또는 화면 폭 768px 이하일 때 활성화 */
@media (max-width: 768px), (pointer: coarse) and (max-width: 1024px) {
    body {
        padding-bottom: 74px !important; /* 하단 탭바 여백 */
        background-color: #f7faf8 !important;
    }

    /* PC 전용 헤더/푸터 숨김 */
    .pc-only-header,
    .pc-only-footer,
    #main-header:not(.m-common-header),
    footer:not(.m-common-footer) {
        display: none !important;
    }

    /* 모바일 공통 상단 헤더 노출 */
    .m-common-header {
        display: block !important;
        position: sticky;
        top: 0;
        left: 0;
        right: 0;
        background: #ffffff;
        z-index: 1000;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
        border-bottom: 1px solid #eef2ef;
    }

    .m-header-container {
        display: flex;
        align-items: center;
        justify-content: space-between;
        height: 54px;
        padding: 0 14px;
    }

    .m-header-logo {
        display: flex;
        align-items: baseline;
        gap: 4px;
        text-decoration: none;
    }

    .m-header-logo .m-brand {
        font-size: 1.25rem;
        font-weight: 800;
        color: var(--primary-color, #1b3022);
        letter-spacing: -0.5px;
        font-family: var(--font-heading);
    }

    .m-header-logo .m-brand-sub {
        font-size: 0.85rem;
        font-weight: 700;
        color: var(--accent-color, #d4af37);
    }

    .m-header-left,
    .m-header-right {
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .m-header-center {
        flex: 1;
        text-align: center;
        min-width: 0;
        padding: 0 8px;
    }

    .m-page-heading {
        font-size: 1.1rem;
        font-weight: 700;
        color: #1b3022;
        margin: 0;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .m-back-action-btn,
    .m-sub-home-btn {
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: #f0f4f1;
        border: none;
        border-radius: 50%;
        color: #1b3022;
        font-size: 0.95rem;
        cursor: pointer;
        text-decoration: none;
    }

    .m-header-install-btn {
        display: inline-flex;
        align-items: center;
        gap: 5px;
        background: var(--primary-color, #1b3022);
        color: #ffffff;
        padding: 5px 12px;
        border-radius: 50px;
        font-size: 0.8rem;
        font-weight: 700;
        border: 1px solid rgba(255, 255, 255, 0.2);
        cursor: pointer;
        box-shadow: 0 2px 6px rgba(27, 48, 34, 0.2);
        transition: all 0.2s ease;
    }

    .m-header-install-btn i {
        color: var(--accent-color, #d4af37);
        font-size: 0.85rem;
    }

    .m-header-install-btn:active {
        transform: scale(0.96);
        background: #284732;
    }

    /* PWA 단독 실행(앱 모드)일 경우 앱설치 버튼 완전 숨김 */
    @media all and (display-mode: standalone) {
        #pwaInstallBtn,
        #pwaSubInstallBtn,
        .m-header-install-btn {
            display: none !important;
        }
    }

    .m-menu-toggle-btn {
        width: 36px;
        height: 36px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 4px;
        background: none;
        border: none;
        cursor: pointer;
        padding: 0;
    }

    .m-menu-toggle-btn span {
        display: block;
        width: 20px;
        height: 2.2px;
        background-color: #1b3022;
        border-radius: 2px;
    }

    /* 사이드 드로어 */
    .m-drawer-overlay {
        display: block !important;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 1098;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
    }

    .m-drawer-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    .m-drawer {
        display: flex !important;
        position: fixed;
        top: 0;
        right: -300px;
        width: 280px;
        height: 100%;
        background: #ffffff;
        z-index: 1099;
        box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
        flex-direction: column;
        transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .m-drawer.active {
        right: 0;
    }

    .m-drawer-header {
        padding: 18px 20px;
        background: #1b3022;
        color: #ffffff;
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
    }

    .m-drawer-title h3 {
        font-size: 1.2rem;
        font-weight: 700;
        margin: 0 0 3px;
        color: #ffffff;
    }

    .m-drawer-title p {
        font-size: 0.78rem;
        color: rgba(255, 255, 255, 0.75);
        margin: 0;
    }

    .m-drawer-close {
        background: none;
        border: none;
        color: #ffffff;
        font-size: 1.6rem;
        line-height: 1;
        cursor: pointer;
        padding: 0;
    }

    .m-drawer-body {
        padding: 18px;
        flex: 1;
        overflow-y: auto;
        display: flex;
        flex-direction: column;
    }

    .m-drawer-nav {
        list-style: none;
        padding: 0;
        margin: 0 0 20px;
    }

    .m-drawer-nav li {
        border-bottom: 1px solid #f0f3f1;
    }

    .m-drawer-nav li a {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px 4px;
        font-size: 0.95rem;
        font-weight: 600;
        color: #333333;
        text-decoration: none;
    }

    .m-drawer-nav li a.active {
        color: var(--primary-color, #1b3022);
        font-weight: 700;
    }

    .m-drawer-nav li a i {
        width: 20px;
        color: var(--primary-color, #1b3022);
    }

    .m-drawer-contact-card {
        background: #f7faf8;
        padding: 14px;
        border-radius: 12px;
        border: 1px solid #e5ede7;
        margin-bottom: 18px;
    }

    .m-drawer-contact-card h4 {
        font-size: 0.85rem;
        margin: 0 0 8px;
        color: #1b3022;
    }

    .m-drawer-call-action {
        display: block;
        background: #1b3022;
        color: #ffffff !important;
        text-align: center;
        padding: 9px;
        border-radius: 8px;
        font-weight: 700;
        font-size: 0.92rem;
        text-decoration: none;
        margin-bottom: 8px;
    }

    .m-drawer-addr-text {
        font-size: 0.75rem;
        color: #667069;
        margin: 0;
        line-height: 1.4;
    }

    .m-drawer-bottom-util {
        margin-top: auto;
        padding-top: 14px;
        text-align: center;
    }

    .m-util-link {
        font-size: 0.85rem;
        color: #555555;
        text-decoration: none;
        display: block;
        margin-bottom: 10px;
    }

    .m-pc-mode-link {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        font-size: 0.82rem;
        color: #667069;
        text-decoration: underline;
    }

    /* 모바일 공통 푸터 */
    .m-common-footer {
        display: block !important;
        background: #18221b;
        color: rgba(255, 255, 255, 0.75);
        padding: 28px 16px 20px;
        text-align: center;
    }

    .m-footer-logo {
        font-size: 1.1rem;
        font-weight: 800;
        color: #ffffff;
        margin-bottom: 8px;
    }

    .m-footer-address {
        font-style: normal;
        font-size: 0.8rem;
        margin-bottom: 6px;
        color: rgba(255, 255, 255, 0.85);
        line-height: 1.4;
    }

    .m-footer-address i {
        color: #d4af37;
    }

    .m-footer-phones {
        font-size: 0.78rem;
        margin-bottom: 14px;
    }

    .m-footer-phones a {
        color: #ffffff;
        font-weight: 600;
    }

    .m-footer-nav-links {
        display: flex;
        justify-content: center;
        gap: 14px;
        margin-bottom: 16px;
    }

    .m-footer-nav-links a {
        color: rgba(255, 255, 255, 0.7);
        font-size: 0.78rem;
        text-decoration: none;
    }

    .m-pc-switch-box {
        margin-bottom: 14px;
    }

    .m-pc-toggle-btn {
        display: inline-flex;
        align-items: center;
        gap: 5px;
        padding: 6px 14px;
        background: rgba(255, 255, 255, 0.1);
        border: 1px solid rgba(255, 255, 255, 0.25);
        border-radius: 50px;
        color: #ffffff;
        font-size: 0.78rem;
        text-decoration: none;
        font-weight: 600;
    }

    .m-footer-copyright {
        font-size: 0.72rem;
        color: rgba(255, 255, 255, 0.45);
        margin: 0;
    }

    /* 모바일 하단 고정 네비게이션 탭바 */
    .m-bottom-nav {
        display: flex !important;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        height: 60px;
        background: #ffffff;
        align-items: center;
        justify-content: space-around;
        z-index: 990;
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.08);
        border-top: 1px solid #eef2ef;
    }

    .m-nav-tab {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 3px;
        text-decoration: none;
        color: #6e7972;
        flex: 1;
        height: 100%;
        background: none;
        border: none;
        padding: 0;
        cursor: pointer;
        font-family: inherit;
    }

    .m-nav-tab i {
        font-size: 1.15rem;
    }

    .m-nav-tab span {
        font-size: 0.7rem;
        font-weight: 600;
    }

    .m-nav-tab.active {
        color: var(--primary-color, #1b3022);
    }

    .m-nav-tab.highlight {
        color: #d9381e;
    }

    /* ==========================================================================
       서브페이지 모바일 최적화 (게시판, 갤러리, 상세, 폼 등)
       ========================================================================== */
    .sub-page,
    .site-content-wrapper > main {
        padding: 12px 0 20px !important;
    }

    .sub-page .container,
    .board-container {
        padding: 14px 12px !important;
        margin-top: 8px !important;
        margin-bottom: 16px !important;
        border-radius: 14px !important;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04) !important;
    }

    .page-header {
        margin-bottom: 16px !important;
    }

    .page-header .subtitle {
        font-size: 1.25rem !important;
    }

    /* 검색 영역 */
    .search-area form {
        display: flex !important;
        gap: 6px !important;
        width: 100% !important;
    }

    .search-area select,
    .search-area input {
        flex: 1 !important;
        min-height: 42px !important;
        font-size: 15px !important;
        border-radius: 8px !important;
        padding: 8px 12px !important;
        box-sizing: border-box !important;
    }

    .search-area .btn {
        padding: 8px 16px !important;
        font-size: 0.9rem !important;
        white-space: nowrap !important;
        border-radius: 8px !important;
    }

    /* 게시판 테이블 -> 모바일 카드형 리스트 변환 */
    .board-table {
        display: block !important;
        width: 100% !important;
        border: none !important;
        margin-top: 12px !important;
    }

    .board-table thead {
        display: none !important;
    }

    .board-table tbody {
        display: flex !important;
        flex-direction: column !important;
        gap: 8px !important;
        width: 100% !important;
    }

    .board-table tbody tr {
        display: flex !important;
        flex-wrap: wrap !important;
        align-items: center !important;
        background: #ffffff !important;
        border: 1px solid #eaf0ec !important;
        border-radius: 12px !important;
        padding: 12px 14px !important;
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02) !important;
        cursor: pointer !important;
        transition: transform 0.15s ease !important;
        box-sizing: border-box !important;
        width: 100% !important;
    }

    .board-table tbody tr:active {
        background: #f7faf8 !important;
        transform: scale(0.99) !important;
    }

    .board-table td {
        border: none !important;
        padding: 0 !important;
        text-align: left !important;
    }

    /* 번호 숨김 */
    .board-table td:nth-child(1),
    .board-table .col-num {
        display: none !important;
    }

    /* 제목 스타일 (1행 전체 차지) */
    .board-table td.title,
    .board-table td:nth-child(2) {
        width: 100% !important;
        font-size: 0.98rem !important;
        font-weight: 700 !important;
        color: #1a1a1a !important;
        margin-bottom: 6px !important;
        line-height: 1.4 !important;
        white-space: normal !important;
        word-break: break-all !important;
        display: block !important;
        order: 1 !important;
    }

    /* 문의게시판 모바일 상태 뱃지 & 타이틀 배치 */
    .qna-title-cell {
        display: flex !important;
        align-items: center !important;
        gap: 6px !important;
        flex-wrap: wrap !important;
    }

    .m-status-badge {
        display: inline-flex !important;
        align-items: center !important;
        gap: 3px !important;
        padding: 2px 6px !important;
        border-radius: 4px !important;
        font-size: 0.72rem !important;
        font-weight: 700 !important;
        flex-shrink: 0 !important;
    }

    .m-status-badge.badge-done {
        background: #e8f8f0 !important;
        color: #27ae60 !important;
    }

    .m-status-badge.badge-wait {
        background: #f1f5f9 !important;
        color: #64748b !important;
    }

    /* PC 전용 상태 컬럼 숨김 (모바일에서는 제목 옆 뱃지로 대체) */
    .pc-status-col {
        display: none !important;
    }

    /* 메타 정보 (작성자, 날짜, 조회수) 2행 한 줄로 나란히 표시 */
    .board-table td:not(.title):not(:nth-child(1)):not(:nth-child(2)):not(.pc-status-col) {
        display: inline-flex !important;
        align-items: center !important;
        gap: 4px !important;
        font-size: 0.78rem !important;
        color: #8c9b90 !important;
        margin-right: 8px !important;
        margin-top: 0 !important;
        order: 2 !important;
        line-height: 1.2 !important;
    }

    /* 메타 정보 사이 구분 기호(·) 추가 */
    .board-table td:not(.title):not(:nth-child(1)):not(:nth-child(2)):not(.pc-status-col):not(:last-child)::after {
        content: "·";
        margin-left: 8px;
        color: #cbd5e1;
        font-weight: bold;
    }

    /* 글쓰기 버튼 */
    .list-btn-area {
        margin-top: 16px !important;
        margin-bottom: 16px !important;
    }

    .list-btn-area .btn {
        width: 100% !important;
        padding: 12px !important;
        font-size: 1rem !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 6px !important;
        box-sizing: border-box !important;
    }

    /* 게시판 상세 페이지 */
    .board-view-header {
        padding-bottom: 16px !important;
        margin-bottom: 20px !important;
        text-align: left !important;
    }

    .board-view-header h3 {
        font-size: 1.35rem !important;
        line-height: 1.35 !important;
        margin-bottom: 10px !important;
    }

    .board-meta {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 8px !important;
        font-size: 0.8rem !important;
    }

    .board-meta span {
        margin-right: 0 !important;
    }

    .board-content {
        padding: 16px 0 !important;
        min-height: 160px !important;
        font-size: 0.98rem !important;
        line-height: 1.75 !important;
        word-break: break-all !important;
    }

    .board-content img {
        max-width: 100% !important;
        height: auto !important;
        border-radius: 8px !important;
    }

    .board-btn-area {
        margin-top: 24px !important;
        padding-top: 16px !important;
        flex-direction: column !important;
        gap: 10px !important;
    }

    .board-btn-area .btn,
    .board-btn-area div {
        width: 100% !important;
        box-sizing: border-box !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
    }

    .board-btn-area div {
        gap: 8px !important;
    }

    .board-btn-area div .btn {
        flex: 1 !important;
    }

    /* 폼 페이지 (글쓰기 / 수정) */
    .board-container form {
        width: 100% !important;
    }

    .form-group {
        margin-bottom: 14px !important;
    }

    .form-group label {
        font-size: 0.9rem !important;
        font-weight: 600 !important;
        margin-bottom: 6px !important;
        display: block !important;
    }

    .form-control,
    input[type="text"],
    input[type="password"],
    input[type="file"],
    textarea,
    select {
        width: 100% !important;
        font-size: 16px !important; /* iOS 자동 줌 방지 */
        min-height: 44px !important;
        padding: 10px 12px !important;
        border-radius: 8px !important;
        box-sizing: border-box !important;
    }

    textarea {
        min-height: 140px !important;
    }

    .form-btn-area {
        margin-top: 20px !important;
        flex-direction: column !important;
        gap: 8px !important;
    }

    .form-btn-area .btn {
        width: 100% !important;
        padding: 12px !important;
        box-sizing: border-box !important;
    }

    /* 갤러리 그리드 모바일 2열 */
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
        margin-bottom: 24px !important;
    }

    .gallery-item .thumb {
        height: 125px !important;
    }

    .gallery-item > div:last-child {
        padding: 10px !important;
    }

    .gallery-item h4 {
        font-size: 0.9rem !important;
        margin: 4px 0 6px !important;
    }

    /* 페이지네이션 */
    .pagination {
        display: flex !important;
        justify-content: center !important;
        gap: 4px !important;
        margin-top: 20px !important;
        flex-wrap: wrap !important;
    }

    .pagination a,
    .pagination span {
        min-width: 34px !important;
        height: 34px !important;
        padding: 0 6px !important;
        font-size: 0.88rem !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        border-radius: 6px !important;
    }

    /* 오시는 길 지도 및 정보 */
    iframe {
        height: 300px !important;
    }
}
