/* Parking Lot CSS - Amber/Gold Theme on Charcoal */

/* Reset and Base Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #0f0f0f;
    color: #e0e0e0;
    line-height: 1.6;
}

.app-container {
    min-height: 100vh;
    padding: 20px;
}

/* Header Styles */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding: 16px 24px;
    background-color: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.header h1 {
    color: #e8a830;
    font-size: 28px;
    font-weight: 600;
}

.idea-count {
    color: #888;
    font-size: 14px;
}

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

/* Connection Status */
.connection-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #ff4444;
}

.status-dot.connected {
    background-color: #4ade80;
}

.status-dot.connecting {
    background-color: #e8a830;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.status-text {
    color: #888;
}

/* Button Styles */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn svg {
    width: 16px;
    height: 16px;
}

.btn-primary {
    background-color: #e8a830;
    color: #0f0f0f;
}

.btn-primary:hover {
    background-color: #d99a20;
    transform: translateY(-1px);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-primary:disabled {
    background-color: #5a4a20;
    cursor: not-allowed;
    transform: none;
}

.btn-secondary {
    background-color: #2a2a2a;
    color: #e0e0e0;
    border: 1px solid #3a3a3a;
}

.btn-secondary:hover {
    background-color: #3a3a3a;
    border-color: #4a4a4a;
}

.btn-promote {
    background-color: #10b981;
    color: #0f0f0f;
    width: 100%;
    justify-content: center;
}

.btn-promote:hover:not(:disabled) {
    background-color: #059669;
    transform: translateY(-1px);
}

.btn-promote:disabled {
    background-color: #4a5a4a;
    cursor: not-allowed;
}

.btn-archive {
    background-color: #6b7280;
    color: #e0e0e0;
    width: 100%;
    justify-content: center;
}

.btn-archive:hover:not(:disabled) {
    background-color: #5b6370;
    transform: translateY(-1px);
}

.btn-archive:disabled {
    background-color: #3a3a3a;
    cursor: not-allowed;
}

/* Filter Styles */
.filters {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
    padding: 16px 24px;
    background-color: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.filter-group label {
    color: #888;
    font-size: 14px;
    white-space: nowrap;
}

.filter-select,
.filter-input {
    padding: 8px 12px;
    background-color: #2a2a2a;
    border: 1px solid #3a3a3a;
    border-radius: 6px;
    color: #e0e0e0;
    font-size: 14px;
    min-width: 150px;
}

.filter-select:focus,
.filter-input:focus {
    outline: none;
    border-color: #e8a830;
}

.filter-input {
    width: 250px;
}

/* Statistics Bar */
.stats-bar {
    display: flex;
    gap: 24px;
    margin-bottom: 24px;
    padding: 12px 24px;
    background-color: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 6px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.stat-label {
    color: #888;
    font-size: 14px;
}

.stat-value {
    color: #e8a830;
    font-size: 18px;
    font-weight: 600;
}

/* Ideas Container */
.ideas-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

/* Idea Card Styles */
.idea-card {
    background-color: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.idea-card:hover {
    border-color: #e8a830;
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(232, 168, 48, 0.15);
}

.idea-card.status-promoted {
    border-left: 4px solid #10b981;
}

.idea-card.status-archived {
    opacity: 0.6;
    border-left: 4px solid #6b7280;
}

.idea-card.status-pending {
    border-left: 4px solid #e8a830;
}

.idea-card-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 12px;
}

.idea-title {
    color: #e0e0e0;
    font-size: 16px;
    font-weight: 500;
    flex: 1;
    margin-right: 12px;
    word-wrap: break-word;
}

.idea-badges {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.badge {
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    font-weight: 600;
    white-space: nowrap;
}

.badge-priority {
    background-color: #3a3a3a;
    color: #e0e0e0;
}

.badge-priority.P0 {
    background-color: #ef4444;
    color: white;
}

.badge-priority.P1 {
    background-color: #f59e0b;
    color: black;
}

.badge-priority.P2 {
    background-color: #e8a830;
    color: #0f0f0f;
}

.badge-priority.P3 {
    background-color: #6b7280;
    color: white;
}

.badge-category {
    background-color: #2a2a2a;
    color: #e8a830;
}

.badge-status {
    font-size: 9px;
    padding: 2px 6px;
    border-radius: 3px;
}

.badge-status.pending {
    background-color: #e8a830;
    color: #0f0f0f;
}

.badge-status.promoted {
    background-color: #10b981;
    color: white;
}

.badge-status.archived {
    background-color: #6b7280;
    color: white;
}

.idea-description {
    color: #888;
    font-size: 13px;
    margin-bottom: 16px;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.idea-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 12px;
}

.tag {
    background-color: #2a2a2a;
    color: #888;
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 12px;
}

.idea-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #666;
    padding-top: 12px;
    border-top: 1px solid #2a2a2a;
}

.idea-meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background-color: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-content-small {
    max-width: 500px;
}

.modal-header {
    padding: 20px;
    background-color: #252525;
    border-bottom: 1px solid #2a2a2a;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    color: #e8a830;
    font-size: 20px;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    color: #e0e0e0;
    font-size: 28px;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

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

.modal-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

/* Idea Detail Styles */
.idea-detail {
    margin-bottom: 24px;
}

.detail-group {
    margin-bottom: 16px;
}

.detail-group label {
    display: block;
    color: #888;
    font-size: 13px;
    margin-bottom: 6px;
    font-weight: 500;
}

.detail-value {
    color: #e0e0e0;
    font-size: 14px;
    line-height: 1.5;
    background-color: #2a2a2a;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #3a3a3a;
}

.detail-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* Action Buttons */
.action-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #2a2a2a;
}

/* Modal Actions */
.modal-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.modal-actions .btn {
    flex: 1;
    justify-content: center;
}

/* Promote Idea Preview */
.promote-idea-preview {
    background-color: #2a2a2a;
    border: 1px solid #3a3a3a;
    border-radius: 6px;
    padding: 12px;
    margin: 16px 0;
}

.promote-idea-preview h4 {
    color: #e8a830;
    font-size: 14px;
    margin-bottom: 8px;
}

.promote-idea-preview p {
    color: #888;
    font-size: 12px;
    margin-bottom: 4px;
}

.promote-idea-preview .preview-title {
    color: #e0e0e0;
    font-size: 14px;
    font-weight: 500;
}

/* Form Styles */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    color: #888;
    font-size: 14px;
    margin-bottom: 6px;
    font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 10px 12px;
    background-color: #2a2a2a;
    border: 1px solid #3a3a3a;
    border-radius: 6px;
    color: #e0e0e0;
    font-size: 14px;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #e8a830;
}

.form-group textarea {
    resize: vertical;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

#addIdeaForm button[type="submit"] {
    width: 100%;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #10b981;
    color: #0f0f0f;
    padding: 12px 20px;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    display: none;
    align-items: center;
    gap: 10px;
    z-index: 2000;
    animation: slideIn 0.3s ease;
}

.toast.active {
    display: flex;
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.toast svg {
    color: #0f0f0f;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Loading State */
.loading {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 60px 20px;
    grid-column: 1 / -1;
}

.loading p {
    color: #888;
    margin-top: 16px;
}

.spinner {
    border: 3px solid #3a3a3a;
    border-top: 3px solid #e8a830;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    grid-column: 1 / -1;
    color: #666;
}

.empty-state svg {
    width: 64px;
    height: 64px;
    margin-bottom: 16px;
    opacity: 0.3;
}

.empty-state h3 {
    color: #888;
    font-size: 18px;
    margin-bottom: 8px;
}

.empty-state p {
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .ideas-container {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }
}

@media (max-width: 768px) {
    .header {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }

    .filters {
        flex-direction: column;
    }

    .filter-group {
        width: 100%;
    }

    .filter-select,
    .filter-input {
        flex: 1;
        width: 100%;
    }

    .stats-bar {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    .ideas-container {
        grid-template-columns: 1fr;
    }

    .detail-row,
    .form-row {
        grid-template-columns: 1fr;
    }

    .modal-content {
        width: 95%;
    }

    .action-buttons {
        grid-template-columns: 1fr;
    }
}

/* Scrollbar Styles */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

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

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

::-webkit-scrollbar-thumb:hover {
    background: #4a4a4a;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mt-4 {
    margin-top: 16px;
}

.mb-4 {
    margin-bottom: 16px;
}