/* TPIX Channel Keywords Styles - Simplified Design */
.tpix-channel-keywords-container {
    max-width: 700px;
    margin: 0 auto;
    padding: 0;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    border: none;
    transition: none;
    position: relative;
}

.tpix-channel-keywords-container:hover {
    box-shadow: none;
}

.tpix-channel-header {
    margin-bottom: 32px;
    text-align: center;
    padding: 0;
}

.tpix-channel-header h2 {
    color: #2B2D42;
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 8px;
    letter-spacing: -0.02em;
}

.tpix-description {
    color: #8D99AE;
    font-size: 0.8rem;
    margin: 0;
    font-weight: 400;
    line-height: 1.5;
}

.tpix-keywords-form {
    margin-bottom: 32px;
}

.tpix-keywords-input-container {
    position: relative;
    min-height: 100px;
    border: 2px solid rgba(141, 153, 174, 0.2);
    border-radius: 12px;
    padding: 20px;
    background: #ffffff;
    margin-bottom: 16px;
    transition: all 0.25s ease;
    box-shadow: 0 2px 8px rgba(43, 45, 66, 0.05);
}

.tpix-keywords-input-container:focus-within {
    border-color: #2B2D42;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(43, 45, 66, 0.1);
}

.tpix-keywords-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.tpix-keyword-tag {
    display: inline-flex;
    align-items: center;
    background: #2B2D42;
    color: #EDF2F4;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    animation: fadeInScale 0.25s ease;
    transition: all 0.2s ease;
    border: none;
}

.tpix-keyword-tag:hover {
    background: #8D99AE;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(43, 45, 66, 0.15);
}

.tpix-keyword-tag span {
    margin-right: 8px;
}

.tpix-keyword-remove {
    background: rgba(237, 242, 244, 0.2);
    border: none;
    color: #EDF2F4;
    cursor: pointer;
    padding: 0;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: bold;
    transition: all 0.2s ease;
}

.tpix-keyword-remove:hover {
    background: #EF233C;
    color: #ffffff;
    transform: scale(1.1);
}

.tpix-keyword-input {
    border: none;
    outline: none;
    background: transparent;
    font-size: 0.9rem;
    padding: 0;
    flex: 1;
    min-width: 200px;
    color: #2B2D42;
    font-weight: 400;
}

.tpix-keyword-input::placeholder {
    color: #8D99AE;
    font-weight: 400;
}

.tpix-keywords-counter {
    text-align: right;
    color: #8D99AE;
    font-size: 0.75rem;
    font-weight: 500;
    margin-bottom: 20px;
    padding: 6px 12px;
    background: rgba(141, 153, 174, 0.1);
    border-radius: 6px;
    border: none;
    display: inline-block;
    margin-left: auto;
    width: fit-content;
}

.tpix-keywords-counter.warning {
    color: #EF233C;
    background: rgba(239, 35, 60, 0.1);
}

.tpix-keywords-counter.danger {
    color: #D90429;
    background: rgba(217, 4, 41, 0.1);
}

.tpix-keywords-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-bottom: 32px;
}

.tpix-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
    position: relative;
    overflow: hidden;
}

.tpix-btn-primary {
    background: #2B2D42;
    color: #EDF2F4;
    border: 1px solid #2B2D42;
    box-shadow: 0 2px 8px rgba(43, 45, 66, 0.15);
}

.tpix-btn-primary:hover {
    background: #8D99AE;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(43, 45, 66, 0.2);
    color: #ffffff;
}

.tpix-btn-primary:disabled {
    background: #8D99AE;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
    color: #EDF2F4;
    opacity: 0.6;
}

.tpix-btn-secondary {
    background: transparent;
    color: #8D99AE;
    border: 1px solid rgba(141, 153, 174, 0.3);
    box-shadow: none;
}

.tpix-btn-secondary:hover {
    background: rgba(141, 153, 174, 0.1);
    transform: translateY(-1px);
    color: #2B2D42;
    border-color: #8D99AE;
}

.tpix-message {
    padding: 12px 16px;
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
    font-size: 0.85rem;
    opacity: 0;
    transition: all 0.3s ease;
    transform: translateY(8px);
    margin-bottom: 20px;
}

.tpix-message.show {
    opacity: 1;
    transform: translateY(0);
}

.tpix-message.success {
    background: rgba(43, 45, 66, 0.05);
    color: #2B2D42;
    border: 1px solid rgba(43, 45, 66, 0.1);
}

.tpix-message.error {
    background: rgba(239, 35, 60, 0.1);
    color: #EF233C;
    border: 1px solid rgba(239, 35, 60, 0.2);
}

/* 추천 패널/칩 스타일 */
.tpix-recommend-panel {
    background: #ffffff;
    border: 1px solid rgba(141, 153, 174, 0.2);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 2px 8px rgba(43, 45, 66, 0.05);
    margin-bottom: 16px;
}

.tpix-reco-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tpix-reco-chip {
    display: inline-flex;
    align-items: center;
    border: 1px solid rgba(141, 153, 174, 0.3);
    background: #fff;
    color: #2B2D42;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tpix-reco-chip:hover {
    background: rgba(141, 153, 174, 0.08);
    transform: translateY(-1px);
}

.tpix-reco-chip .score {
    margin-left: 8px;
    color: #8D99AE;
    font-size: 0.75rem;
}

.tpix-keywords-preview {
    background: #ffffff;
    border: 1px solid rgba(141, 153, 174, 0.2);
    border-radius: 12px;
    padding: 20px;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(43, 45, 66, 0.05);
}

.tpix-keywords-preview:hover {
    border-color: rgba(141, 153, 174, 0.3);
    box-shadow: 0 2px 12px rgba(43, 45, 66, 0.08);
}

.tpix-keywords-preview h3 {
    margin-top: 0;
    margin-bottom: 16px;
    color: #2B2D42;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.tpix-keywords-preview pre {
    background: #2B2D42;
    color: #EDF2F4;
    padding: 16px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 0;
    font-family: 'SF Mono', 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.75rem;
    line-height: 1.5;
    border: none;
}

.tpix-error {
    background: rgba(239, 35, 60, 0.1);
    color: #EF233C;
    padding: 16px;
    border-radius: 8px;
    border: 1px solid rgba(239, 35, 60, 0.2);
    text-align: center;
    font-weight: 500;
    font-size: 0.85rem;
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(4px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* 반응형 스타일 개선 */
@media (max-width: 768px) {
    .tpix-channel-keywords-container {
        margin: 0 8px;
        padding: 0;
    }
    
    .tpix-channel-header h2 {
        font-size: 1.1rem;
    }
    
    .tpix-description {
        font-size: 0.7rem;
    }
    
    .tpix-channel-header {
        margin-bottom: 24px;
    }
    
    .tpix-keywords-actions {
        flex-direction: column;
        gap: 8px;
    }
    
    .tpix-btn {
        width: 100%;
        padding: 10px 16px;
        font-size: 0.75rem;
    }
    
    .tpix-keyword-input {
        min-width: 150px;
        font-size: 16px; /* iOS 줌 방지 */
    }
    
    .tpix-keywords-input-container {
        padding: 14px;
        border-radius: 10px;
    }
    
    .tpix-keywords-tags {
        gap: 6px;
    }
    
    .tpix-keyword-tag {
        padding: 4px 8px;
        font-size: 0.7rem;
    }
    
    .tpix-keywords-counter {
        font-size: 0.7rem;
        padding: 5px 10px;
    }
    
    .tpix-message {
        font-size: 0.75rem;
        padding: 10px 14px;
    }
    
    .tpix-keywords-preview h3 {
        font-size: 0.8rem;
    }
    
    .tpix-keywords-preview pre {
        font-size: 0.7rem;
        padding: 12px;
    }
    
    .tpix-error {
        font-size: 0.75rem;
        padding: 12px;
    }
}

/* 더 작은 모바일 화면에서 여백 최소화 */
@media (max-width: 480px) {
    .tpix-channel-keywords-container {
        margin: 0 4px;
    }
    
    .tpix-keywords-input-container {
        padding: 12px;
    }
    
    .tpix-keywords-preview {
        padding: 16px;
    }
} 