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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #1a1a1a;
    color: #ffffff;
}

.gallery-container {
    max-width: 1800px;
    margin: 0 auto;
    padding: 20px;
}

.header {
    padding: 20px;
    background: #1a1a1a;
    border-bottom: 1px solid #333;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.register-btn {
    padding: 10px 20px;
    background-color: #1565C0;
    color: #ffffff;
    text-decoration: none;
    border: none;
    border-radius: 5px;
    font-weight: bold;
    transition: all 0.3s ease;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.register-btn i {
    font-size: 16px;
}

.register-btn:hover {
    background-color: #0D47A1;
    transform: translateY(-2px);
}

.gallery-title {
    font-size: 24px;
    font-weight: bold;
    color: #fff;
    margin: 0;
}

.search-bar {
    display: flex;
    align-items: center;
    background: #2a2a2a;
    border-radius: 20px;
    padding: 8px 15px;
    width: 400px;
    position: relative;
}

.search-bar input {
    width: 100%;
    padding: 12px 40px 12px 12px;
    border-radius: 5px;
    border: 1px solid #333;
    background-color: #2a2a2a;
    color: white;
    font-size: 16px;
}

.search-bar i {
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    pointer-events: auto;
    cursor: pointer;
}

.filter-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
}

.categories {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.category {
    padding: 8px 16px;
    border-radius: 20px;
    background-color: #2a2a2a;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.category:hover {
    background-color: #3a3a3a;
}

.category.active {
    background-color: #4a4a4a;
}

.sort-section {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sort-select {
    padding: 8px 16px;
    border-radius: 5px;
    background-color: #2a2a2a;
    border: 1px solid #333;
    color: white;
    cursor: pointer;
}

.items-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px 0;
}

.item-card {
    background-color: #2a2a2a;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease;
    cursor: pointer;
}

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

.item-audio {
    position: relative;
    padding: 15px;
    background: #1a1a1a;
}

.waveform-container {
    display: none;
}

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

.audio-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

.play-button {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background: #1565C0;
    color: #ffffff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.play-button:hover {
    background: #0D47A1;
    transform: translateY(-2px);
}

.progress-bar {
    flex-grow: 1;
    height: 4px;
    background: #333;
    border-radius: 2px;
    cursor: pointer;
    position: relative;
}

.progress {
    height: 100%;
    background: #1565C0;
    border-radius: 2px;
    width: 0;
}

.duration {
    font-size: 0.9em;
    color: #fff;
}

.item-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    padding: 10px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.7), transparent);
    color: white;
    display: flex;
    justify-content: space-between;
}

.rating, .downloads, .format {
    display: flex;
    align-items: center;
    gap: 5px;
}

.item-info {
    padding: 15px;
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.item-content {
    flex: 1;
    margin-bottom: 50px;
}

.item-actions {
    position: absolute;
    bottom: 15px;
    left: 15px;
    right: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: flex-end;
    background: #2a2a2a;
    padding: 10px;
    border-top: 1px solid #333;
}

.item-actions .downloads {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #666;
    font-size: 14px;
    margin-right: auto;
}

.item-actions .downloads i {
    color: #4CAF50;
}

.download-button {
    padding: 8px 16px;
    background-color: #1565C0;
    color: #ffffff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.download-button:hover {
    background-color: #0D47A1;
}

.download-button .download-text {
    font-size: 14px;
    color: #fff;
    margin-right: 2px;
}

.download-button .download-count {
    font-size: 13px;
    color: #00ff88;
    margin-left: 2px;
    min-width: 18px;
    text-align: right;
}

.edit-button, .delete-button {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.edit-button {
    background-color: #1565C0;
    color: #ffffff;
}

.edit-button:hover {
    background-color: #0D47A1;
    transform: translateY(-2px);
}

.delete-button {
    background-color: #ff5252;
    color: white;
}

.delete-button:hover {
    background-color: #ff1744;
    transform: translateY(-2px);
}

.item-title {
    font-weight: 600;
    margin-bottom: 5px;
    color: #fff;
}

.item-category {
    color: #1565C0;
    font-size: 0.9em;
    margin-bottom: 10px;
}

.item-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 10px;
}

.tag {
    background: #333;
    color: #fff;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8em;
}

.item-price {
    font-weight: 600;
    color: #1565C0;
    margin-bottom: 10px;
}

.audio-details {
    display: flex;
    gap: 15px;
    font-size: 0.9em;
    color: #ccc;
}

/* 스크롤바 스타일링 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #1a1a1a;
}

::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #444;
}

/* 로딩 인디케이터 */
.loading {
    text-align: center;
    padding: 20px;
    color: #ccc;
}

.error-message {
    text-align: center;
    padding: 20px;
    color: #ff5252;
}

.no-items {
    text-align: center;
    padding: 40px;
    color: #ccc;
    font-size: 18px;
}

/* 모달 스타일 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 1000;
}

.modal-content {
    position: relative;
    background-color: #2a2a2a;
    margin: 50px auto;
    padding: 20px;
    width: 90%;
    max-width: 800px;
    border-radius: 8px;
    max-height: 90vh;
    overflow-y: auto;
}

.close-button {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 24px;
    color: #fff;
    cursor: pointer;
}

/* 폼 스타일 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #ccc;
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #333;
    border-radius: 5px;
    background-color: #1a1a1a;
    color: white;
}

.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

.submit-button {
    padding: 10px 20px;
    background-color: #1565C0;
    color: #ffffff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

.submit-button:hover {
    background-color: #0D47A1;
    transform: translateY(-2px);
}

.cancel-button {
    padding: 10px 20px;
    background-color: #666;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.cancel-button:hover {
    background-color: #888;
    transform: translateY(-2px);
}

.btn-category {
    margin-right: 8px;
    margin-bottom: 8px;
    padding: 6px 18px;
    border: none;
    border-radius: 20px;
    background: #23272f;
    color: #fff;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.btn-category.active, .btn-category:hover {
    background: #3b82f6;
    color: #fff;
} 