.peteitcms-virtual-gifts-shop {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    background: #111b21;
    min-height: 100vh;
}

.gifts-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid #2a3942;
}

.gifts-header h2 {
    margin: 0;
    font-size: 28px;
    color: #e9edef;
}

.user-balance {
    font-size: 18px;
    padding: 10px 20px;
    background: #202c33;
    border-radius: 4px;
    color: #e9edef;
    border: 1px solid #2a3942;
}

.user-balance strong {
    color: #00a884;
}

.author-selection {
    margin-bottom: 30px;
    background: #202c33;
    padding: 20px;
    border: 1px solid #2a3942;
    border-radius: 4px;
}

/* Category Filter */
.category-filter {
    margin-bottom: 30px;
    padding: 20px;
    background: #202c33;
    border: 1px solid #2a3942;
    border-radius: 4px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.category-btn {
    padding: 10px 20px;
    background: #111b21;
    border: 1px solid #2a3942;
    border-radius: 4px;
    color: #e9edef;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
}

.category-btn:hover {
    background: #2a3942;
    border-color: #00a884;
}

.category-btn.active {
    background: #00a884;
    border-color: #00a884;
    color: #111b21;
    font-weight: bold;
}

.custom-select-wrapper {
    position: relative;
    width: 100%;
    max-width: 400px;
}

.custom-select-trigger {
    padding: 12px 40px 12px 15px;
    background: #111b21;
    border: 1px solid #2a3942;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    position: relative;
    transition: border-color 0.2s;
}

.custom-select-trigger:hover,
.custom-select-wrapper.active .custom-select-trigger {
    border-color: #00a884;
}

.custom-select-trigger::after {
    content: '▼';
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #8696a0;
    font-size: 10px;
    transition: transform 0.2s;
}

.custom-select-wrapper.active .custom-select-trigger::after {
    transform: translateY(-50%) rotate(180deg);
}

.select-placeholder {
    color: #8696a0;
    font-size: 16px;
}

.custom-select-trigger.has-value .select-placeholder {
    color: #e9edef;
}

.custom-select-trigger .option-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.custom-select-options {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #202c33;
    border: 1px solid #2a3942;
    border-radius: 4px;
    margin-top: 5px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none !important;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.custom-select-wrapper.active .custom-select-options {
    display: block !important;
}

.custom-option {
    padding: 10px 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: background 0.2s;
}

.custom-option:hover {
    background: #111b21;
}

.custom-option.selected {
    background: #00a884;
}

.custom-option.selected .option-name {
    color: #111b21;
    font-weight: 600;
}

.option-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.option-name {
    color: #e9edef;
    font-size: 16px;
}

.custom-select-options::-webkit-scrollbar {
    width: 6px;
}

.custom-select-options::-webkit-scrollbar-track {
    background: #111b21;
}

.custom-select-options::-webkit-scrollbar-thumb {
    background: #374045;
    border-radius: 3px;
}

.gifts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
}

.gift-card {
    background: #202c33;
    border: 1px solid #2a3942;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
}

.gift-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,168,132,0.3);
    border-color: #00a884;
}

.gift-image {
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: #111b21;
}

.gift-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gift-info {
    padding: 10px;
}

.gift-name {
    margin: 0 0 8px 0;
    font-size: 14px;
    font-weight: 600;
    color: #e9edef;
    text-align: center;
    height: 2.8em;
    line-height: 1.4em;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.gift-price {
    font-size: 16px;
    font-weight: bold;
    color: #00a884;
    margin-bottom: 10px;
    text-align: center;
}

.gift-card .button {
    width: calc(100% - 20px);
    margin: 0 10px 10px;
    text-align: center;
    padding: 8px;
    background: #00a884;
    color: #111b21;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s;
}

.gift-card .button:hover {
    background: #06cf9c;
    transform: scale(1.02);
}

/* Modal */
.gift-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999999;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.85);
}

.modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #202c33;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    border: 1px solid #2a3942;
}

.modal-content::-webkit-scrollbar {
    width: 6px;
}

.modal-content::-webkit-scrollbar-track {
    background: #111b21;
}

.modal-content::-webkit-scrollbar-thumb {
    background: #374045;
    border-radius: 3px;
}

.modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 30px;
    cursor: pointer;
    color: #8696a0;
    z-index: 1;
    transition: color 0.2s;
}

.modal-close:hover {
    color: #e9edef;
}

.modal-body {
    padding: 30px;
}

.gift-preview {
    width: 100%;
    aspect-ratio: 1 / 1;
    margin-bottom: 20px;
    border-radius: 8px;
    overflow: hidden;
    background: #111b21;
    border: 1px solid #2a3942;
}

.gift-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gift-details h3 {
    margin: 0 0 15px 0;
    font-size: 24px;
    color: #e9edef;
}

.gift-details .gift-price {
    font-size: 24px;
    font-weight: bold;
    color: #00a884;
    margin-bottom: 20px;
}

.recipient-info {
    background: #111b21;
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
    border: 1px solid #2a3942;
    color: #e9edef;
}

#confirm-purchase {
    width: 100%;
    padding: 15px;
    font-size: 18px;
    font-weight: 600;
    background: #00a884;
    color: #111b21;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

#confirm-purchase:hover {
    background: #06cf9c;
    transform: scale(1.02);
}

#confirm-purchase:disabled {
    background: #374045;
    color: #667781;
    cursor: not-allowed;
    transform: none;
}

.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.alert-warning {
    background: #2a3942;
    border: 1px solid #374045;
    color: #e9edef;
}

.loading {
    text-align: center;
    padding: 40px;
    color: #8696a0;
    font-size: 16px;
}

/* Alert Modal */
.alert-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000000;
}

.alert-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #202c33;
    border-radius: 8px;
    padding: 30px;
    min-width: 300px;
    max-width: 500px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    border: 1px solid #2a3942;
    text-align: center;
}

.alert-content.success {
    border-top: 4px solid #00a884;
}

.alert-content.error {
    border-top: 4px solid #ff6b6b;
}

.alert-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #8696a0;
    transition: color 0.2s;
}

.alert-modal-close:hover {
    color: #e9edef;
}

.alert-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: bold;
}

.alert-content.success .alert-icon {
    background: rgba(0, 168, 132, 0.2);
    color: #00a884;
}

.alert-content.error .alert-icon {
    background: rgba(255, 107, 107, 0.2);
    color: #ff6b6b;
}

.alert-message {
    color: #e9edef;
    font-size: 16px;
    margin-bottom: 20px;
    line-height: 1.5;
}

.alert-ok-btn {
    background: #00a884;
    color: #111b21;
    border: none;
    padding: 10px 30px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.alert-ok-btn:hover {
    background: #06cf9c;
    transform: scale(1.05);
}
