/* Common styles that were likely in common.css */
:root {
    --primary: #1987fa;
    --secondary: #10c2a0;
    --wht: #ffffff;
    --blk: #333333;
    --gray50: #f8f9fa;
    --gray100: #e9ecef;
    --gray300: #adb5bd;
    --gray500: #6c757d;
    --gray700: #495057;
    --error: #dc3545;
    --accent: #ffc107;
    --primary-lightest: #e8f3ff;
    --primary-lighter: #d1e7ff;
    --gradient-blue-green: linear-gradient(135deg, #1987fa, #10c2a0);
    --border-radius: 8px;
    --radius-pill: 50px;
    --box-shadow-light: 0 2px 8px rgba(0, 0, 0, 0.07);
    --box-shadow-medium: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* --- Modular CSS Imports --- */
/* @import url('search_components.css'); */
/* @import url('ai_search.css'); */
/* @import url('flight_results.css'); */

/* 전체 layout: 메인 wrapper */
.main-content {
    min-height: 100vh;
    background: #f9f9f9;
}

/* --- Hero Section --- */
.hero-section {
    width: 100%;
    height: 250px;
    background: var(--gradient-blue-green);
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-section .top_airplane,
.hero-section .top_cloud_left,
.hero-section .top_cloud_right,
.hero-section .top_main_cloud {
    position: absolute;
    opacity: 1;
    pointer-events: none;
}

.hero-section .top_airplane {
    left: 9%;
    bottom: 50%;
    width: 10%;
}

.hero-section .top_cloud_left {
    left: 0;
    bottom: -20px;
    width: 250px;
}

.hero-section .top_cloud_right {
    right: 0;
    bottom: 0px;
    width: 200px;
    mix-blend-mode: hard-light
}

.hero-section .top_main_cloud {
    top: 20px;
    right: 20%;
    width: 300px;
}

.title {
    text-align: center;
    position: relative;
    color: #FEFF80;
    font-size: 38px;
    line-height: 1.3;
    z-index: 10;
    font-weight: bold;
}

.title_2 {
    color: var(--wht);
    display: inline-block;
    font-size: 42px;
}

/* --- Main Content --- */
main {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-bottom: 50px;
    position: relative;
}

/* --- Search Box --- */
#search {
    width: 100%;
    position: relative;
    margin-top: 40px;
    z-index: 20;
    display: flex;
    justify-content: center;
    overflow: visible;
}

.search_box {
    width: 100%;
    max-width: 1200px;
    background-color: var(--wht);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-medium);
    display: flex;
    flex-direction: column;
    overflow: visible;
}

.search_box_top {
    display: flex;
    align-items: center;
    padding: 12px 25px;
    border-bottom: 1px solid var(--gray100);
}

.trip-btn {
    margin-right: 8px;
    padding: 7px 16px;
    border-radius: var(--radius-pill);
    border: none;
    background: var(--gray50);
    color: var(--primary);
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.trip-btn.active {
    background: var(--primary);
    color: var(--wht);
}

.search_box_top label {
    font-size: 14px;
    margin-left: 12px;
    color: var(--gray700);
}

.search_box_mb {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    padding: 20px 25px;
    overflow: visible;
}

.search_box_mid {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
}

.swap-btn {
    border: none;
    background: transparent;
    cursor: pointer;
    margin: 0 6px;
    align-self: center;
}

.swap-btn img {
    width: 28px;
    height: 28px;
}

.calendar-container {
    display: flex;
    align-items: center;
    overflow: visible;
    gap: 10px;
}

.calendar-label {
    font-size: 14px;
    color: var(--gray700);
    margin-right: 6px;
    position: relative;
}

#depart-calendar,
#return-calendar {
    border: 1px solid var(--gray100);
    border-radius: var(--border-radius);
    padding: 8px 12px;
    width: 110px;
    font-size: 14px;
}

.flatpickr-calendar {
    position: fixed;
    top: 124px;
    left: 605px;
    right: auto;
}

.passenger-select-wrapper {
    position: relative;
}

#passenger-btn {
    border: 1px solid var(--gray100);
    border-radius: var(--border-radius);
    background: var(--wht);
    padding: 8px 14px;
    font-size: 14px;
    color: var(--blk);
    cursor: pointer;
}

.dropdown {
    display: none;
    position: absolute;
    top: 40px;
    left: 0;
    background: var(--wht);
    border: 1px solid var(--gray100);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-light);
    z-index: 10;
    min-width: 150px;
    padding: 10px;
}

.passenger-select-wrapper.active .dropdown {
    display: block;
}

#search-flights-btn {
    background: var(--primary);
    color: var(--wht);
    border: none;
    border-radius: var(--border-radius);
    padding: 10px 18px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

#search-flights-btn:hover {
    background: var(--secondary);
}

.suggestions-dropdown {
    display: none;
    position: absolute;
    top: 38px;
    left: 0;
    width: 100%;
    background: var(--wht);
    border: 1px solid var(--gray100);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-light);
    z-index: 20;
    font-size: 15px;
}

/* --- AI Assistant box (search area 아래) --- */
.ai-assistant-box {
    background: var(--gray50);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-light);
    margin-top: 18px;
    padding: 22px;
}

.ai-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ai-badge {
    background: var(--primary);
    color: #fff;
    border-radius: 5px;
    padding: 2px 8px;
    font-size: 12px;
    margin-right: 6px;
}

.ai-ip-box {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 14px;
}

.ai-cloud {
    width: 36px;
    height: 36px;
}

.ai-input-box {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ai-input {
    width: 100%;
    border: 1px solid var(--gray100);
    border-radius: var(--border-radius);
    padding: 9px 14px;
    font-size: 15px;
}

.ai-search-btn {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
}

.ai-search-btn:after {
    content: '🔍';
    color: #fff;
    font-size: 17px;
}

.ai-notification {
    margin-top: 7px;
    font-size: 13px;
    color: var(--accent);
}

/* --- Checklist (오른쪽) --- */
.top_right {
    position: absolute;
    top: 100px;
    right: calc(50% - 600px + 20px);
    width: 280px;
    z-index: 1;
    display: none;
}

.checklist-box {
    background: var(--wht);
    border-radius: var(--border-radius);
    padding: 20px;
    box-shadow: var(--box-shadow-light);
}

.checklist-title {
    font-weight: 700;
    font-size: 16px;
    color: var(--blk);
    margin-bottom: 16px;
}

.checklist-items li {
    display: flex;
    align-items: center;
    padding: 12px 0;
    border-top: 1px solid #eee;
}

.checklist-items li:first-child {
    border-top: none;
}

.checklist-items img {
    width: 28px;
    height: 28px;
    margin-right: 12px;
}

.text-box strong {
    font-size: 14px;
    color: var(--blk);
    line-height: 1.4;
}

.text-box span {
    font-size: 12px;
    color: var(--gray500);
}

.arrow {
    font-size: 18px;
    color: var(--gray300);
    margin-left: auto;
}

/* --- AI Recommendation Section --- */
.ai-recommendation-section {
    width: 100%;
    max-width: 1200px;
    margin: 60px auto 40px auto;
    padding: 0 20px;
}

.ai-section-header-wrap {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 20px;
    position: relative;
}

.ai-section-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--blk);
    margin-bottom: 10px;
}

.ai-section-description {
    font-size: 14px;
    color: var(--gray700);
    line-height: 1.5;
    text-align: center;
}

.ai-header-buttons {
    display: flex;
    position: absolute;
    top: 0;
    right: 0;
    gap: 8px;
}

.ai-header-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 7px 16px;
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--radius-pill);
    border: 1px solid var(--gray100);
    background: var(--gray50);
    color: var(--primary);
    cursor: pointer;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.ai-header-btn img {
    width: 16px;
    height: 16px;
    filter: brightness(0) saturate(100%) invert(51%) sepia(83%) saturate(700%) hue-rotate(161deg) brightness(94%) contrast(94%);
}

.ai-header-btn.active {
    background: var(--gradient-blue-green);
    color: var(--wht);
    border-color: transparent;
}

.ai-header-btn.active img {
    filter: brightness(0) invert(1);
}

/* MODIFIED: Default to column, set gap */
.ai-content-wrapper {
    display: flex;
    flex-direction: column;
    /* Default to vertical stacking */
    min-height: 527px;
    gap: 20px;
}

/* AI Keywords Panel */
/* MODIFIED: Remove flex property, set width to 100% */
.ai-keywords-panel {
    padding: 24px 20px;
    background-color: var(--wht);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-light);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
}

.ai-panel-title {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 16px;
    color: var(--primary);
}

.word-cloud-container {
    position: relative;
    width: 100%;
    height: 450px;
    background: linear-gradient(132deg, rgba(25, 135, 250, 0.50) 0%, rgba(16, 194, 160, 0.50) 94.35%);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-light);
    overflow: hidden;
    margin-bottom: 20px;
}

.word {
    position: absolute;
    display: inline-block;
    cursor: pointer;
    transition: transform 0.3s ease, fill 0.3s ease, filter 0.3s ease;
    font-weight: 600;
    animation: float 4s ease-in-out infinite;
    line-height: 24px;
}

text {
    display: inline-block;
    white-space: pre-wrap;
    fill: var(--wht);
    width: 40px;
    height: 100%;
}

.word:hover {
    transform: scale(1.2) translateY(-5px);
    fill: var(--primary);
    filter: brightness(1.2);
}

.word.active {
    width: 40px;
    height: 100%;
    background-color: var(--primary);
    fill: var(--wht);
    display: inline-block;
    font-weight: bolder;
    font-size: 38px;
    transform: scale(1.25) translateY(-8px);
    border-radius: 8px;
    padding: 4px 8px;
    border: 1px solid var(--wht);
}

.word-tooltip {
    position: absolute;
    display: inline-block;
    width: 40px;
    background-color: var(--wht);
    color: var(--wht);
    padding: 0.5rem;
    border-radius: 4px;
    font-size: 1.5rem;
    display: none;
    z-index: 10;
    pointer-events: none;
}

.word:hover+.word-tooltip {
    display: block;
}

.ai-status-indicator {
    position: absolute;
    bottom: 16px;
    right: 16px;
    display: flex;
    align-items: center;
    color: var(--gray500);
    font-size: 14px;
}

.ai-loading-spinner {
    width: 20px;
    height: 20px;
    margin-right: 4px;
    color: var(--primary);
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.ai-keyword-controls {
    width: 100%;
    display: flex;
    flex-direction: row;
    gap: 10px;
    align-items: center;
}

.ai-filter-select {
    width: 100%;
    padding: 8px;
    height: 40px;
    border: 1px solid var(--gray100);
    border-radius: var(--border-radius);
    color: var(--gray700);
    background-color: var(--wht);
    transition: all 0.15s ease-in-out;
    font-size: 15px;
}

.ai-filter-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.ai-more-keywords-btn {
    width: 100%;
    background: var(--primary);
    color: var(--wht);
    padding: 8px;
    height: 40px;
    border-radius: var(--border-radius);
    transition: background 0.2s;
    position: relative;
    overflow: hidden;
    z-index: 1;
    border: none;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    box-shadow: var(--box-shadow-light);
}

.ai-more-keywords-btn:hover {
    background: var(--secondary);
}

#keyword-panel-content-wrapper {
    width: 100%;
}

/* Recommendation Cards Panel */
/* MODIFIED: Remove flex property, set width to 100% */
.ai-recommendation-cards-panel {
    width: 100%;
    padding: 24px 20px;
    background-color: var(--wht);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-light);
    position: relative;
}

.ai-recommendation-cards-panel .ai-panel-title {
    margin-bottom: 16px;
    text-align: left;
}

.carousel-wrapper {
    width: 100%;
    overflow-x: hidden;
    position: relative;
}

.recommendation-grid {
    display: flex;
    flex-wrap: nowrap;
    transition: transform 0.5s ease;
    width: 100%;
    overflow: visible;
}

.card {
    display: flex;
    flex: 0 0 100%;
    overflow-y: hidden;
    border-radius: var(--border-radius);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-container {
    display: flex;
    gap: 30px;
}

#card-con-top {
    display: flex;
}

.card:hover {
    transform: translateY(-5px);
    /* box-shadow: var(--box-shadow-medium); */
}

.card-image-wrap {
    position: relative;
    max-width: 390px;
    height: 444px;
    overflow: hidden;
    border-radius: var(--border-radius);
}

.card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.card-badge {
    position: absolute;
    display: flex;
    align-items: center;
    top: 10px;
    left: 10px;
    background-color: var(--wht);
    color: var(--primary);
    border: 1px solid var(--primary);
    padding: 4px 10px;
    border-radius: var(--border-radius);
    font-size: 14px;
    font-weight: bold;
    text-align: center;
    z-index: 2;
}

.card-content-wrapper {
    padding: 20px 34px 20px 0px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
}

#card-con-right {
    padding: 0;
    /* height: 444px; */
    max-width: 50%;
    display: flex;
    flex-direction: column;
    /* justify-content: space-between; */
}

.card-info-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 8px;
    font-size: 16px;
    color: var(--gray300);
}

.card h3 {
    font-size: 24px;
    font-weight: 700;
    color: var(--blk);
    margin-bottom: 8px;
    line-height: 1.3;
}

.card-tags {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.card-tag-item {
    color: var(--primary);
    font-size: 12px;
    font-weight: bold;
    margin-right: 8px;
    border-radius: var(--radius-pill);
    white-space: nowrap;
}

.ai-match-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-top: 15px;
    background-color: var(--primary-lightest);
    padding: 10px;
    border-radius: var(--border-radius);
    border: 1px solid var(--primary-lighter);
    width: 428px;
    height: auto;
    max-width: 100%;
}

.ai-match-icon {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    flex-shrink: 0;
    animation: pulse 2s infinite;
    filter: drop-shadow(0 0 3px rgba(251, 191, 36, 0.4));
}

.ai-match-text {
    flex-grow: 1;
    color: var(--primary);
    font-size: 16px;
    font-weight: bolder;
    line-height: 1.4;
}

.ai-match-text strong {
    font-weight: 800;
    color: var(--primary);
}

.ai-info-icon {
    display: flex;
}

.ai-info-text2 {
    display: block;
    margin-top: 4px;
    font-size: 16px;
    line-height: 26px;
    color: var(--gray500);
}

.ai-reason-text {
    display: block;
    margin-top: 4px;
    font-size: 16px;
    color: var(--gray500);
    line-height: 28px;
    margin-top: 12px;
}

.price-bt {
    display: flex;
    flex-direction: column;
    padding: 0px 34px 0px 0px;
    align-items: flex-end;
}

.price-info {
    font-size: 16px;
    font-weight: normal;
    color: var(--gray500);
    margin-top: 15px;
    width: 100%;
    text-align: right;
}

.price-info .card-price {
    color: var(--error);
    font-size: 28px;
    font-weight: 700;
    margin-left: 5px;
}

.book-now-button {
    margin-top: 15px;
    /* width: 70%; */
    background: var(--gradient-blue-green);
    color: var(--wht);
    padding: 10px 18px;
    height: 40px;
    border-radius: var(--border-radius);
    transition: opacity 0.15s ease-in-out, transform 0.15s ease;
    position: relative;
    overflow: hidden;
    z-index: 1;
    border: none;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    box-shadow: var(--box-shadow-light);
}

.book-now-button:hover {
    opacity: 0.95;
    transform: translateY(-1px);
}

.book-now-button:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2), 0 0 0 4px rgba(255, 255, 255, 0.5);
}

.carousel-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.4);
    color: var(--wht);
    padding: 10px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    box-shadow: var(--box-shadow-light);
    transition: background-color 0.2s, transform 0.2s;
}

.carousel-button:hover {
    background: rgba(0, 0, 0, 0.6);
    transform: translateY(-50%) scale(1.05);
}

.carousel-button.left {
    left: 10px;
}

.carousel-button.right {
    right: 10px;
}

.carousel-button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    background: rgba(0, 0, 0, 0.2);
    transform: translateY(-50%);
    box-shadow: none;
}

/* General Glow Button Effect */
.glow-button {
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.glow-button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 300%;
    height: 300%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
    transition: all 0.7s ease-out;
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
    z-index: -1;
}

.glow-button:hover::before {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

/* Modal Overlay (General) */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.open {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background-color: var(--wht);
    padding: 32px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-medium);
    transform: scale(0.9);
    transition: transform 0.3s ease;
    max-width: 500px;
    width: 90%;
    text-align: center;
}

.modal-overlay.open .modal-content {
    transform: scale(1);
}

.modal-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 16px;
}

.modal-message {
    color: var(--gray700);
    margin-bottom: 24px;
}

.modal-close-button {
    background-color: var(--primary);
    color: var(--wht);
    padding: 8px 24px;
    border-radius: var(--border-radius);
    transition: background-color 0.15s ease-in-out;
    position: relative;
    overflow: hidden;
    z-index: 1;
    border: none;
    cursor: pointer;
}

.modal-close-button:hover {
    background-color: var(--secondary);
}

.modal-close-button:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2), 0 0 0 4px rgba(255, 255, 255, 0.5);
}

/* Particle animation for SVG */
@keyframes float {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-12px);
    }

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

.particle {
    display: none;
    animation: float 6s ease-in-out infinite;
}

#word-cloud-svg path,
#word-cloud-svg circle {
    display: none;
}

/* --- 추천 카드 --- */
.recom_box {
    width: 280px;
    background: var(--wht);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-light);
    overflow: hidden;
    transition: transform 0.2s ease;
}

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

.recom_box_img {
    position: relative;
    height: 180px;
    overflow: hidden;
}

.recom_box_img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.recom_percent {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: var(--secondary);
    color: var(--wht);
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 6px;
    font-weight: 600;
}

.recom_tag {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.6);
    color: var(--wht);
    font-size: 11px;
    padding: 4px 8px;
    border-radius: 6px;
}

.recom_box_text {
    padding: 16px;
}

.recom_box_text h3 {
    margin: 0 0 10px;
    font-size: 16px;
    color: var(--blk);
    font-weight: 700;
}

.recom_box_text p {
    margin: 6px 0;
    font-size: 13px;
    color: var(--gray500);
}

.recom_box_text small {
    font-size: 11px;
    color: var(--gray300);
}

.direct_badge {
    background: var(--primary);
    color: var(--wht);
    font-size: 10px;
    padding: 3px 7px;
    border-radius: var(--radius-pill);
    margin-left: 6px;
    font-weight: 600;
}

/* --- Banner Swiper --- */
.banner-swiper-container {
    width: 100%;
    max-width: 1200px;
    height: 90px;
    margin: 50px auto;
    background-color: #136DFF;
    border-radius: var(--border-radius);
    overflow: hidden;
    position: relative;
    box-shadow: var(--box-shadow-light);
}

.myBannerSwiper {
    width: 100%;
    height: 100%;
}

.myBannerSwiper .swiper-slide {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

.myBannerSwiper .swiper-slide img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
}

.myBannerSwiper .swiper-pagination {
    position: absolute;
    bottom: 8px;
    right: 16px;
    font-size: 12px;
    color: var(--wht);
    width: auto;
    text-align: right;
    padding: 4px 8px;
    border-radius: 4px;
}

/* --- Theme Travel Section --- */
.theme-travel {
    width: 100%;
    max-width: 1200px;
    margin: 60px auto 40px auto;
    padding: 0 20px;
}

.theme-travel h2 {
    font-size: 22px;
    font-weight: 700;
    color: var(--blk);
    margin-bottom: 25px;
}

.theme-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
}

.theme-card {
    height: 240px;
    border-radius: var(--border-radius);
    overflow: hidden;
    background: var(--wht);
    box-shadow: var(--box-shadow-light);
    display: flex;
    flex-direction: column;
    transition: transform 0.2s ease;
}

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

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

.theme-card .text-box {
    padding: 12px 15px;
    font-size: 14px;
    color: var(--gray700);
}

.theme-card .text-box strong {
    display: block;
    font-weight: 700;
    margin-bottom: 4px;
    font-size: 15px;
    color: var(--blk);
}

.theme-card .text-box .price {
    color: var(--primary);
    font-weight: 700;
    margin-right: 5px;
    font-size: 16px;
}

.more-btn-wrap {
    text-align: center;
    margin-top: 80px;
}

.more-theme {
    background: var(--gradient-blue-green);
    color: var(--wht);
    font-weight: 600;
    border: none;
    border-radius: var(--radius-pill);
    padding: 12px 28px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--box-shadow-light);
}

.more-theme:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

/* --- Responsive (중요!) --- */
/* MODIFIED: Media query for desktop layout (1024px and wider) */
@media (min-width: 1024px) {
    .ai-content-wrapper {
        flex-direction: row;
        align-items: stretch;
    }

    .ai-keywords-panel {
        flex: 1;
        /* 1 part of the width */
        width: auto;
        /* Reset width for flex behavior */
    }

    .ai-recommendation-cards-panel {
        flex: 2;
        /* 2 parts of the width */
        width: auto;
        /* Reset width for flex behavior */
        max-width: 50vw;
        min-width: 40vw;
    }
}

@media (max-width: 1199px) {

    .main-content,
    .search_box,
    .recommend,
    .banner-swiper-container,
    .theme-travel {
        width: 100%;
        padding: 0px 0px;
    }

    .hero-section {
        height: 200px;
    }

    .title {
        font-size: 30px;
    }

    .title_2 {
        font-size: 35px;
    }

    .recom_box {
        width: 220px;
    }
}

@media (max-width: 1023px) {

    .word-cloud-container {
        position: relative;
        width: 100%;
        height: 200px;
        background: linear-gradient(132deg, rgba(25, 135, 250, 0.50) 0%, rgba(16, 194, 160, 0.50) 94.35%);
        border-radius: var(--border-radius);
        box-shadow: var(--box-shadow-light);
        overflow: hidden;
        margin-bottom: 20px;
    }

    .hero-section {
        height: 180px;
    }

    .title {
        font-size: 26px;
    }

    .title_2 {
        font-size: 30px;
    }

    .banner-swiper-container,
    .recommend,
    .theme-travel {
        padding: 0 10px;
    }

    .theme-grid {
        /* grid-template-columns: 2fr; */
        gap: 10px;
    }

    .theme-card {
        height: 400px;
    }

    .theme-card img {
        height: 300px;
    }

    .recom_box {
        width: 100%;
    }

    .swiper-button-prev,
    .swiper-button-next,
    .gradient-left,
    .gradient-right {
        display: none;
    }
}

@media (max-width: 767px) {
    /* --- 추가된 코드 시작 --- */
    .ai-content-wrapper {
        min-height: auto; /* 모바일에서 최소 높이 제한을 제거하여 하단 여백을 없앱니다. */
    }

    .card {
        height: auto; /* 카드의 높이를 콘텐츠에 맞게 자동으로 조절합니다. */
    }
    /* --- 추가된 코드 끝 --- */

    .hero-section {
        height: 120px;
    }

    .search_box {
        padding: 0;
    }

    .theme-grid {
        grid-template-columns: 1fr;
    }

    .more-theme {
        font-size: 14px;
        padding: 10px 16px;
    }

    .card-container {
        flex-direction: column;
        gap: 10px;
    }

    #card-con-right {
        max-width: 100%;
    }
    .card-image-wrap{
        max-width: none;
        height: 250px; /* 이미지 높이를 적절하게 지정합니다. */
      }
   #card-con-left{
    height: auto; /* 높이를 자동으로 조절하도록 변경합니다. */
   }
    .card-content-wrapper{
        padding: 20px; /* 모바일 화면에 맞게 패딩을 조정합니다. */
    }
}

@media (max-width: 480px) {

    .main-content,
    .recommend,
    .theme-travel,
    .banner-swiper-container {
        padding: 0 5px;
    }

    .title {
        font-size: 20px;
    }

    .title_2 {
        font-size: 24px;
    }

    .theme-card {
        height: 300px;
    }

    .theme-card img {
        height: 200px;
    }
}