/* --- Floating Bottom Bar & Participation Center --- */

.floating-bottom-bar {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    width: 90%;
    max-width: 500px;
    height: 50px;
    border-radius: 25px;
    background: rgba(27, 58, 107, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
    z-index: 9000;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: #fff;
}

.floating-bottom-bar.state-b {
    background: #2563EB;
    width: auto;
    min-width: 200px;
    padding: 0 25px;
}

.floating-content {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    padding: 0 20px;
}

.state-a-content {
    display: flex;
}

.state-b-content {
    justify-content: center;
    transition: opacity 0.3s;
    display: none; /* Default hidden */
    white-space: nowrap;
}

#floating-action-text {
    font-size: 13px;
    white-space: nowrap;
}

.floating-bottom-bar.state-b .state-a-content {
    display: none !important;
}

.floating-bottom-bar.state-b .state-b-content {
    display: flex !important;
}


.state-b-content:hover {
    opacity: 0.9;
}

/* Participation Modal */
.participation-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 10000;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    animation: fadeIn 0.3s;
}

.participation-content {
    background: #fff;
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    height: 85vh;
    border-radius: 20px 20px 0 0;
    display: flex;
    flex-direction: column;
    box-shadow: 0 -5px 25px rgba(0,0,0,0.2);
    animation: slideUp 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.part-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #DBEAFE;
}

.part-title {
    font-size: 16px;
    font-weight: bold;
    color: #1B3A6B;
}

.part-close-btn {
    font-size: 24px;
    cursor: pointer;
    color: #64748B;
}

.part-tabs {
    display: flex;
    border-bottom: 1px solid #DBEAFE;
}

.part-tab {
    flex: 1;
    text-align: center;
    padding: 12px;
    font-size: 13px;
    font-weight: bold;
    color: #64748B;
    cursor: pointer;
}

.part-tab.active {
    color: #2563EB;
    border-bottom: 2px solid #2563EB;
}

.part-tab-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    font-size: 12px;
    font-weight: bold;
    color: #555;
    margin-bottom: 6px;
}

.btn-attach {
    padding: 8px 12px;
    background: #f4f4f4;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
}

.btn-submit-part {
    width: 100%;
    padding: 14px;
    background: #2563EB;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    margin-top: 10px;
}

.my-part-card {
    border: 1px solid #eee;
    border-radius: 8px;
    padding: 12px;
    background: #f9f9f9;
}

.my-part-title {
    font-weight: bold;
    font-size: 13px;
    margin-bottom: 4px;
}

@keyframes slideUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}


@media (min-width: 768px) {
    .floating-bottom-bar {
        left: 270px;
        right: 15px;
        width: auto;
        max-width: none;
        transform: none;
        border-radius: 12px;
    }
    /* 제안하기 버튼 상태일 때는 작은 알약으로 */
    .floating-bottom-bar.state-b {
        left: auto;
        right: 15px;
        width: auto;
        min-width: 200px;
        max-width: 280px;
        border-radius: 25px;
    }
}
