/* ==========================================
   SpeedMag — roadmap.css
   Kanban board & submit modal styles
   ========================================== */

/* ----- Active nav link ----- */
.nav-active {
    color: var(--accent-cyan) !important;
}

/* ----- Roadmap Hero ----- */
.roadmap-hero {
    position: relative;
    padding: calc(var(--nav-height) + 64px) 0 48px;
    text-align: center;
    overflow: hidden;
}

.roadmap-hero-glow {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 400px;
    background: radial-gradient(ellipse, rgba(16,185,129,0.06) 0%, transparent 60%);
    pointer-events: none;
}

.roadmap-hero .section-header {
    margin-bottom: 32px;
}

/* ----- Board Section ----- */
.roadmap-board-section {
    padding: 24px 0 var(--section-pad);
}

.roadmap-board-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 16px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.roadmap-board {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    min-width: 900px;
}

/* ----- Columns ----- */
.roadmap-column {
    background: rgba(255,255,255,0.015);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px;
    min-height: 400px;
}

.column-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.column-header h3 {
    font-size: 0.9rem;
    font-weight: 600;
    flex: 1;
}

.column-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.column-dot.submitted { background: #8a9e96; }
.column-dot.under-review { background: #f59e0b; }
.column-dot.in-progress { background: #3b82f6; }
.column-dot.shipped { background: #10B981; }

.column-count {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-secondary);
    background: rgba(255,255,255,0.06);
    padding: 2px 8px;
    border-radius: var(--radius-pill);
}

.column-cards {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* ----- Idea Cards ----- */
.idea-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 16px;
    transition: all 0.2s;
    cursor: default;
}

.idea-card:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
}

.idea-title {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 6px;
    line-height: 1.3;
}

.idea-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.idea-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.idea-author {
    font-size: 0.75rem;
    color: var(--text-secondary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 120px;
}

.idea-upvote {
    display: flex;
    align-items: center;
    gap: 5px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: var(--radius-pill);
    padding: 4px 12px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
}

.idea-upvote:hover {
    border-color: var(--accent-cyan);
    color: var(--accent-cyan);
    background: rgba(16,185,129,0.06);
}

.idea-upvote.voted {
    color: var(--accent-cyan);
    border-color: rgba(16,185,129,0.3);
    background: rgba(16,185,129,0.08);
    cursor: default;
}

.idea-upvote svg {
    flex-shrink: 0;
}

/* Admin response on card */
.idea-response {
    margin-top: 10px;
    padding: 10px 12px;
    background: rgba(16,185,129,0.04);
    border-left: 2px solid var(--accent-cyan);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    font-size: 0.78rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.idea-response-label {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--accent-cyan);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 4px;
}

/* Shipped link */
.idea-changelog {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--accent-cyan);
    transition: opacity 0.2s;
}

.idea-changelog:hover {
    opacity: 0.8;
}

/* ----- Submit Modal ----- */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 24px;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    width: 100%;
    max-width: 520px;
    max-height: 90vh;
    overflow-y: auto;
}

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

.modal-header h2 {
    font-size: 1.3rem;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    transition: color 0.2s;
}

.modal-close:hover {
    color: var(--text);
}

.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 6px;
}

.required {
    color: #ef4444;
}

.optional {
    color: var(--text-secondary);
    font-weight: 400;
}

.form-group input,
.form-group textarea {
    width: 100%;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--text);
    transition: border-color 0.2s;
    outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--accent-cyan);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.char-count {
    position: absolute;
    right: 0;
    top: 0;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.form-row {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.form-success {
    text-align: center;
    padding: 32px 0 16px;
}

.form-success h3 {
    margin: 16px 0 8px;
    font-size: 1.2rem;
}

.form-success p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 24px;
}

/* ----- Loading & Empty States ----- */
.loading-state {
    text-align: center;
    padding: 40px 16px;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.loading-spinner {
    width: 24px;
    height: 24px;
    border: 2px solid var(--border);
    border-top-color: var(--accent-cyan);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 12px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.empty-state {
    text-align: center;
    padding: 32px 16px;
    color: var(--text-secondary);
    font-size: 0.8rem;
}

/* ----- Responsive ----- */
@media (max-width: 768px) {
    .roadmap-hero {
        padding-top: calc(var(--nav-height) + 40px);
    }

    .roadmap-board {
        min-width: 280px;
        grid-template-columns: 1fr;
    }

    .roadmap-column {
        min-height: auto;
    }

    .modal {
        padding: 24px;
    }

    .nav-links.active a {
        font-size: 1.5rem;
    }
}
