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

:root {
    /* Soft & Warm Palette */
    --primary-color: #E06A3A;
    --primary-hover: #C85A2E;
    --primary-light: rgba(224, 106, 58, 0.10);
    --primary-glow: rgba(224, 106, 58, 0.20);
    --accent-cyan: #3A72C4;
    --accent-warm: #E06A3A;
    --success-color: #3A8F5C;
    --success-light: rgba(58, 143, 92, 0.10);
    --danger-color: #D04040;
    --danger-light: rgba(208, 64, 64, 0.10);
    --warning-color: #C49A1A;
    --warning-light: rgba(196, 154, 26, 0.10);

    /* Background & Surfaces */
    --background: #FAF8F5;
    --background-alt: #F3F0EB;
    --surface: #FFFFFF;
    --surface-solid: #FFFFFF;
    --surface-elevated: #FFFFFF;
    --surface-hover: #F3F0EB;

    /* Text Colors */
    --text-primary: #1A1A1A;
    --text-secondary: #6B6560;
    --text-muted: #A49E96;
    --text-inverse: #FFFFFF;

    /* Borders & Dividers */
    --border: #E8E4DD;
    --border-light: #F0ECE6;
    --border-focus: #E06A3A;

    /* Shadows – soft & warm */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.03);
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 4px 12px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 2px 8px rgba(0, 0, 0, 0.05), 0 8px 24px rgba(0, 0, 0, 0.04);
    --shadow-lg: 0 4px 12px rgba(0, 0, 0, 0.06), 0 12px 32px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 8px 24px rgba(0, 0, 0, 0.08), 0 16px 40px rgba(0, 0, 0, 0.06);
    --shadow-floating: 0 12px 40px rgba(0, 0, 0, 0.1), 0 4px 16px rgba(0, 0, 0, 0.05);
    --shadow-glow: none;

    /* Font stacks */
    --font-heading: 'DM Sans', -apple-system, sans-serif;
    --font-body: 'DM Sans', -apple-system, sans-serif;

    /* Border Radius */
    --radius-xs: 4px;
    --radius-sm: 6px;
    --radius: 10px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-2xl: 24px;
    --radius-full: 9999px;

    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing: 0.75rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;

    /* Transitions – smooth, no springy bouncing */
    --transition: all 0.15s ease;
    --transition-fast: all 0.1s ease;
    --transition-slow: all 0.25s ease;
    --transition-spring: all 0.2s ease;

    --label-bg-mix: white;
    --glass-blur: none;
    --glass-border: 1px solid #E8E4DD;
    --sticky-surface: rgba(250, 248, 245, 0.94);
    --sticky-shadow: 0 10px 28px rgba(26, 26, 26, 0.06);
}

[data-theme="dark"] {
    --background: #1A1816;
    --background-alt: #211F1C;
    --surface: #242120;
    --surface-solid: #2A2725;
    --surface-elevated: #302D2A;
    --surface-hover: #352F2C;

    --text-primary: #F0ECE8;
    --text-secondary: #A89E94;
    --text-muted: #6B6058;
    --text-inverse: #1A1816;

    --border: #3A3532;
    --border-light: #302D2A;
    --border-focus: #E06A3A;

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 16px 40px rgba(0, 0, 0, 0.6);
    --shadow-floating: 0 24px 56px rgba(0, 0, 0, 0.7);
    --shadow-glow: none;

    --primary-light: rgba(224, 106, 58, 0.12);
    --success-light: rgba(58, 143, 92, 0.12);
    --danger-light: rgba(208, 64, 64, 0.12);
    --warning-light: rgba(196, 154, 26, 0.12);
    --primary-glow: rgba(224, 106, 58, 0.25);
    --label-bg-mix: #2A2725;

    --glass-border: 1px solid #3A3532;
    --sticky-surface: rgba(26, 24, 22, 0.92);
    --sticky-shadow: 0 14px 32px rgba(0, 0, 0, 0.28);
}

/* Animated gradient background */
body {
    font-family: var(--font-body);
    background: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    -webkit-tap-highlight-color: transparent;
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
    position: relative;
    min-height: 100vh;
    overflow-x: hidden;
}

/* No background animation — clean, solid background */

.container {
    max-width: 960px;
    margin: 0 auto;
    padding: var(--spacing-lg);
    min-height: 100vh;
    position: relative;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: var(--spacing-2xl);
    padding: var(--spacing-2xl) 0 var(--spacing-xl) 0;
    position: relative;
    animation: headerReveal 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.header.hidden {
    display: none;
}

@keyframes headerReveal {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header icon buttons (shared) */
.settings-btn,
.theme-toggle-btn {
    position: absolute;
    top: var(--spacing-xl);
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: var(--radius-md);
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition);
    z-index: 10;
    box-shadow: var(--shadow-sm);
}

.settings-btn { right: 0; }
.theme-toggle-btn { right: 52px; }

.settings-btn svg,
.theme-toggle-btn svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.settings-btn:hover,
.theme-toggle-btn:hover {
    background: var(--surface-elevated);
    color: var(--text-primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.settings-btn:active,
.theme-toggle-btn:active {
    transform: translateY(0) scale(0.95);
}

.header h1 {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 5vw, 2.75rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--spacing-sm);
    letter-spacing: -0.03em;
    line-height: 1.1;
}

.header .subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 500;
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.5;
}

/* Settings Modal */
.settings-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.settings-modal.hidden {
    display: none;
}

.modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.modal-content {
    position: relative;
    background: var(--surface-solid);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-floating);
    max-width: 480px;
    width: 90%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    border: var(--glass-border);
}

.modal-header {
    padding: var(--spacing-lg) var(--spacing-xl);
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-family: var(--font-heading);
    color: var(--text-primary);
    font-size: 1.25rem;
    font-weight: 700;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-secondary);
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    transition: var(--transition);
}

.close-btn:hover {
    background: var(--surface-hover);
    color: var(--text-primary);
}

.modal-body {
    padding: var(--spacing-xl);
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    padding: var(--spacing-xl);
    border-top: 1px solid var(--border);
    display: flex;
    gap: var(--spacing-md);
    justify-content: flex-end;
}

.settings-section h3 {
    color: var(--text-primary);
    margin-bottom: var(--spacing-md);
    font-size: 1.1rem;
    font-family: var(--font-heading);
}

.settings-description {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: var(--spacing-lg);
    line-height: 1.5;
}

/* Checkbox Container */
.checkbox-container {
    display: flex !important;
    flex-direction: row !important;
    align-items: center;
    cursor: pointer;
    user-select: none;
    gap: var(--spacing-sm);
    min-height: 44px;
    padding: 4px 0;
}

.checkbox-container input[type="checkbox"] {
    display: none;
}

.checkmark {
    display: block;
    width: 24px !important;
    height: 24px !important;
    min-width: 24px;
    min-height: 24px;
    background: var(--surface-solid);
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    position: relative;
    transition: var(--transition-spring);
    flex: 0 0 24px;
}

.checkbox-container input[type="checkbox"]:checked + .checkmark {
    background: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.checkbox-container input[type="checkbox"]:checked + .checkmark::after {
    content: '';
    position: absolute;
    top: 4px;
    left: 7px;
    width: 6px;
    height: 10px;
    border: solid white;
    border-width: 0 2.5px 2.5px 0;
    transform: rotate(45deg);
}

.checkbox-container:hover .checkmark {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.hidden {
    display: none !important;
}

.loading {
    text-align: center;
    color: var(--text-muted);
    padding: var(--spacing-xl);
    font-size: 0.95rem;
}

/* App Grid */
.app-selection h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: var(--spacing-xl);
    color: var(--text-primary);
    text-align: center;
    animation: fadeInUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.notification-panel {
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    margin: 0 auto var(--spacing-xl) auto;
    max-width: 760px;
    box-shadow: var(--shadow-md);
}

.notification-panel h3 {
    font-family: var(--font-heading);
    font-size: 1rem;
    margin-bottom: var(--spacing-xs);
}

.notification-panel p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: var(--spacing-md);
}

.notification-panel-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-sm);
}

.notification-toggle-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--spacing-md);
    margin-bottom: 0;
}

.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-lg);
}

.app-card {
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: var(--radius-xl);
    padding: var(--spacing-xl) var(--spacing-xl) var(--spacing-lg);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    box-shadow: var(--shadow);
    overflow: hidden;
    animation: cardEntrance 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.app-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.app-card:active {
    transform: translateY(-2px) scale(0.99);
}

@keyframes cardEntrance {
    from {
        opacity: 0;
        transform: translateY(24px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Stagger animation for app cards */
.app-card:nth-child(1) { animation-delay: 0.05s; }
.app-card:nth-child(2) { animation-delay: 0.1s; }
.app-card:nth-child(3) { animation-delay: 0.15s; }
.app-card:nth-child(4) { animation-delay: 0.2s; }
.app-card:nth-child(5) { animation-delay: 0.25s; }
.app-card:nth-child(6) { animation-delay: 0.3s; }

.app-card h3 {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: var(--spacing-sm);
    line-height: 1.3;
}

.app-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* View Header */
.suggestions-topbar {
    display: flex;
    flex-direction: column;
    gap: var(--spacing);
    margin-bottom: var(--spacing-lg);
}

.suggestions-topbar .view-header {
    margin-bottom: 0;
}

.view-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
    animation: fadeInUp 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.view-header h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
}

.back-btn {
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
    box-shadow: var(--shadow-sm);
}

.back-btn::before {
    content: '\2190';
    font-size: 1.1rem;
}

.back-btn:hover {
    background: var(--surface-elevated);
    color: var(--text-primary);
    transform: translateX(-2px);
    box-shadow: var(--shadow-md);
}

/* Buttons */
.primary-btn, .secondary-btn {
    padding: 10px 20px;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 600;
    font-family: var(--font-body);
    cursor: pointer;
    transition: var(--transition);
    border: none;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    position: relative;
    overflow: hidden;
}

.primary-btn {
    background: var(--text-primary);
    color: var(--text-inverse);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.primary-btn:hover {
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
    transform: translateY(-1px);
}

.primary-btn:active {
    transform: translateY(0) scale(0.98);
    box-shadow: 0 1px 4px rgba(99, 102, 241, 0.3);
}

.primary-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.secondary-btn {
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    color: var(--text-secondary);
    border: var(--glass-border);
    box-shadow: var(--shadow-sm);
}

.secondary-btn:hover {
    background: var(--surface-elevated);
    color: var(--text-primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

/* Header action button (replaces FAB) */
.header-action-btn {
    margin-left: auto;
    white-space: nowrap;
    padding: 10px 20px;
    font-size: 0.875rem;
}

.mobile-inline-action-btn {
    display: none;
    width: 100%;
    justify-content: center;
}

.filter-bar-host:empty {
    display: none;
}

.filter-bar-host .filter-bar {
    margin-bottom: 0;
}

.actions {
    margin-bottom: var(--spacing-lg);
}

/* Suggestions */
.suggestions-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.suggestion-card {
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: var(--radius-lg);
    padding: var(--spacing-xl);
    transition: var(--transition);
    position: relative;
    box-shadow: var(--shadow);
    animation: cardEntrance 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* Stagger suggestion cards */
.suggestion-card:nth-child(2) { animation-delay: 0.03s; }
.suggestion-card:nth-child(3) { animation-delay: 0.06s; }
.suggestion-card:nth-child(4) { animation-delay: 0.09s; }
.suggestion-card:nth-child(5) { animation-delay: 0.12s; }
.suggestion-card:nth-child(6) { animation-delay: 0.15s; }
.suggestion-card:nth-child(7) { animation-delay: 0.18s; }
.suggestion-card:nth-child(8) { animation-delay: 0.21s; }
.suggestion-card:nth-child(9) { animation-delay: 0.24s; }
.suggestion-card:nth-child(10) { animation-delay: 0.27s; }

.suggestion-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

[data-theme="dark"] .suggestion-card:hover {
    box-shadow: var(--shadow-lg), 0 0 0 1px rgba(148, 163, 184, 0.08);
}

.suggestion-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-sm);
}

.suggestion-content {
    flex: 1;
}

.suggestion-title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--spacing-xs);
    line-height: 1.3;
}

.suggestion-description {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: var(--spacing-sm);
}

/* Labels (status, comment, etc.) */
.label {
    --label-color: var(--text-secondary);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--label-color);
    background: color-mix(in srgb, var(--label-color) 10%, var(--label-bg-mix));
    border: none;
    line-height: 1.4;
    letter-spacing: 0.01em;
}

.label-button {
    cursor: pointer;
    transition: var(--transition-fast);
}

.label-button:hover {
    background: color-mix(in srgb, var(--label-color) 18%, var(--label-bg-mix));
    transform: translateY(-1px);
}

.label-dot {
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: var(--label-color);
    flex: 0 0 auto;
}

/* Filter bar */
.filter-groups {
    display: grid;
    gap: 10px;
    margin-bottom: var(--spacing-lg);
    animation: fadeInUp 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.filter-group {
    display: grid;
    gap: 6px;
}

.filter-group-label {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted);
    padding-left: 2px;
}

.filter-bar {
    display: flex;
    gap: 6px;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin-bottom: 0;
    padding: 4px 0;
}

.filter-bar::-webkit-scrollbar {
    display: none;
}

.filter-pill {
    --filter-color: var(--text-primary);
    appearance: none;
    border: var(--glass-border);
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    color: var(--text-secondary);
    border-radius: var(--radius-full);
    padding: 7px 14px;
    font-size: 0.8125rem;
    font-weight: 600;
    font-family: var(--font-body);
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    flex-shrink: 0;
    box-shadow: var(--shadow-sm);
}

.filter-pill:hover {
    background: var(--surface-elevated);
    color: var(--text-primary);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.filter-pill.active {
    background: var(--surface-solid);
    border-color: var(--border);
    color: var(--text-primary);
    box-shadow: var(--shadow-md);
}

.filter-pill .filter-dot {
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: var(--filter-color);
}

.filter-pill.active .filter-dot {
    background: var(--filter-color);
}

.filter-count {
    padding: 1px 7px;
    border-radius: var(--radius-full);
    background: var(--border-light);
    color: var(--text-muted);
    font-size: 0.7rem;
    font-weight: 700;
}

.filter-pill.active .filter-count {
    background: var(--primary-light);
    color: var(--primary-color);
}

/* Vote Column Layout */
.suggestion-layout {
    display: flex;
    gap: var(--spacing-lg);
    align-items: flex-start;
}

.vote-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    flex-shrink: 0;
    width: 48px;
    padding-top: 2px;
}

.upvote-btn {
    background: none;
    border: 2px solid transparent;
    cursor: pointer;
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1;
    padding: 6px 10px;
    border-radius: var(--radius-md);
    transition: var(--transition-spring);
    display: flex;
    align-items: center;
    justify-content: center;
}

.upvote-btn:hover:not(:disabled) {
    color: var(--primary-color);
    background: var(--primary-light);
    border-color: var(--primary-light);
    transform: scale(1.15);
}

.upvote-btn:active:not(:disabled) {
    animation: voteBounce 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes voteBounce {
    0% { transform: scale(1); }
    30% { transform: scale(1.4) translateY(-4px); }
    60% { transform: scale(0.9); }
    100% { transform: scale(1.15); }
}

.upvote-btn.voted {
    color: var(--primary-color);
    background: var(--primary-light);
}

.upvote-btn:disabled {
    cursor: default;
    opacity: 0.4;
}

.vote-column .vote-count {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--text-muted);
    line-height: 1;
}

.vote-column .vote-count.voted {
    color: var(--primary-color);
}

.bug-icon-column,
.ticket-icon-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
    width: 48px;
    padding-top: 4px;
    color: var(--text-muted);
    font-size: 1.1rem;
    opacity: 0.6;
}

.suggestion-layout .suggestion-content {
    flex: 1;
    min-width: 0;
}

/* Ticket number */
.ticket-number {
    font-family: 'JetBrains Mono', 'SF Mono', 'Fira Code', 'Consolas', monospace;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-muted);
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 1px 6px;
    border-radius: 4px;
    white-space: nowrap;
    flex-shrink: 0;
}

.suggestion-title-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.suggestion-title-row .suggestion-title {
    margin: 0;
}

/* Priority badge */
.priority-badge {
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 2px 8px;
    border-radius: 9999px;
    background: color-mix(in srgb, var(--priority-color) 15%, transparent);
    color: var(--priority-color);
    white-space: nowrap;
    flex-shrink: 0;
}

/* Label pills */
.label-pill {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 500;
    padding: 2px 8px;
    border-radius: 9999px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    margin-right: 4px;
}

/* Form */
.suggestion-form {
    max-width: 600px;
    margin: 0 auto;
    animation: fadeInUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.form-group {
    margin-bottom: var(--spacing-lg);
}

.form-group label {
    display: block;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--spacing-sm);
    font-size: 0.875rem;
    font-family: var(--font-heading);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    font-family: var(--font-body);
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    color: var(--text-primary);
    transition: var(--transition);
    resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-glow);
    background: var(--surface-elevated);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
    opacity: 1;
}

.form-actions {
    display: flex;
    gap: var(--spacing-sm);
    justify-content: flex-end;
    margin-top: var(--spacing-xl);
}

/* Toast Notifications */
.toast {
    position: fixed;
    top: var(--spacing-lg);
    right: var(--spacing-lg);
    padding: 12px 20px;
    background: var(--surface-solid);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    color: var(--text-primary);
    font-size: 0.875rem;
    font-weight: 600;
    font-family: var(--font-body);
    transform: translateX(calc(100% + 2rem));
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 3000;
    max-width: 380px;
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.toast.show {
    transform: translateX(0);
}

.toast.success {
    border-left: 3px solid var(--success-color);
}

.toast.success::before {
    content: '\2713';
    color: var(--success-color);
    font-weight: 800;
    font-size: 1rem;
}

.toast.error {
    border-left: 3px solid var(--danger-color);
}

.toast.error::before {
    content: '!';
    color: var(--danger-color);
    font-weight: 800;
    font-size: 1rem;
}

.toast.warning {
    border-left: 3px solid var(--warning-color);
}

.toast.warning::before {
    content: '!';
    color: var(--warning-color);
    font-weight: 800;
    font-size: 1rem;
}

/* Success Overlay */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: var(--spacing-lg);
    animation: overlayFadeIn 0.25s ease both;
}

@keyframes overlayFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.overlay-content {
    background: var(--surface-solid);
    border-radius: var(--radius-2xl);
    padding: var(--spacing-2xl);
    max-width: 420px;
    width: 100%;
    box-shadow: var(--shadow-floating);
    text-align: center;
    animation: overlaySlideUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) both;
    border: var(--glass-border);
}

@keyframes overlaySlideUp {
    from {
        transform: translateY(24px) scale(0.95);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

.overlay-icon {
    width: 72px;
    height: 72px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    margin: 0 auto 24px auto;
    box-shadow: 0 4px 20px rgba(224, 106, 58, 0.25);
}

@keyframes iconPop {
    from {
        transform: scale(0) rotate(-30deg);
    }
    to {
        transform: scale(1) rotate(0deg);
    }
}

/* Success Overlay content */
.overlay-content h2 {
    margin: 0 0 12px 0;
    color: var(--text-primary);
    font-family: var(--font-heading);
    font-weight: 800;
}

.overlay-content p {
    margin: 0 0 24px 0;
    color: var(--text-secondary);
    text-align: center;
    line-height: 1.6;
}

.overlay-content .primary-btn {
    width: 100%;
    padding: 12px 20px;
}

/* Image Modal */
.image-modal-inner {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-modal-inner img {
    max-width: 100%;
    max-height: 90vh;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-floating);
}

.image-modal-close {
    position: absolute;
    top: -15px;
    right: -15px;
    background: var(--surface-solid);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 24px;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    transition: var(--transition);
}

.image-modal-close:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-xl);
}

/* Comments section */
.comments-section {
    display: none;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-light);
    animation: fadeInUp 0.3s ease both;
}

.comments-section.is-visible {
    display: block;
}

.comments-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.comment-card {
    background: var(--surface-hover);
    border-radius: var(--radius-md);
    padding: 14px;
    border: var(--glass-border);
}

.comment-header {
    display: flex;
    align-items: start;
    gap: 8px;
    margin-bottom: 4px;
}

.comment-author-badge {
    background: var(--primary-color);
    color: white;
    padding: 2px 10px;
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.comment-author-badge.is-user {
    background: #0f766e;
}

.comment-date {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.comment-text {
    margin: 8px 0 0 0;
    white-space: pre-wrap;
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--text-primary);
}

.comment-screenshots {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.comment-screenshot {
    max-width: 200px;
    max-height: 200px;
    border-radius: var(--radius-md);
    cursor: pointer;
    border: 2px solid var(--border);
    object-fit: cover;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.comment-screenshot:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

.comments-error {
    color: var(--danger-color);
    padding: 8px;
    font-size: 0.9rem;
}

.comments-empty {
    color: var(--text-muted);
    font-size: 0.9rem;
    font-style: italic;
}

.comment-composer {
    margin-top: 14px;
    padding: 14px;
    background: var(--surface-hover);
    border: var(--glass-border);
    border-radius: var(--radius-md);
}

.comment-composer h4 {
    margin: 0 0 6px 0;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.comment-composer-hint {
    margin: 0 0 10px 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.45;
}

.comment-composer-textarea {
    width: 100%;
    min-height: 88px;
    resize: vertical;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: var(--surface-solid);
    color: var(--text-primary);
    padding: 12px;
    font: inherit;
    line-height: 1.5;
}

.comment-composer-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 10px;
}

.comment-preview-item {
    position: relative;
    display: inline-block;
}

.comment-preview-thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid var(--border);
}

.comment-preview-remove {
    position: absolute;
    top: -6px;
    right: -6px;
    width: 20px;
    height: 20px;
    border: none;
    border-radius: 999px;
    background: var(--danger-color);
    color: white;
    cursor: pointer;
    line-height: 1;
    font-size: 12px;
    padding: 0;
}

/* Badge spacing */
.badge-row {
    margin-top: 8px;
}

/* Form hint text */
.form-hint {
    display: block;
    color: var(--text-muted);
    font-size: 0.8rem;
    margin-top: var(--spacing-xs);
}

/* Screenshot upload preview */
.screenshot-preview-grid {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: var(--spacing-sm);
}

.screenshot-thumb {
    position: relative;
    width: 72px;
    height: 72px;
    border-radius: var(--radius-sm);
    overflow: visible;
    border: 1px solid var(--border);
    flex-shrink: 0;
}

.screenshot-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--radius-sm);
}

.screenshot-thumb .remove-btn {
    position: absolute;
    top: -6px;
    right: -6px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--danger-color);
    color: white;
    border: 2px solid var(--surface-solid);
    font-size: 11px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

/* Bug screenshots in cards */
.bug-screenshots {
    display: flex;
    gap: 6px;
    margin-top: var(--spacing-sm);
    flex-wrap: wrap;
}

.bug-screenshots img {
    width: 64px;
    height: 64px;
    object-fit: cover;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    cursor: pointer;
    transition: var(--transition);
}

.bug-screenshots img:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-md);
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: var(--spacing-md);
        padding-top: 60px;
    }

    .header {
        margin-bottom: var(--spacing-xl);
        padding-top: calc(42px + var(--spacing-lg));
        padding-bottom: var(--spacing-md);
    }

    .theme-toggle-btn {
        top: var(--spacing-sm);
        right: 0;
    }

    .header h1 {
        font-size: 2.25rem;
    }

    .header .subtitle {
        font-size: 0.95rem;
    }

    .app-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .notification-toggle-row {
        flex-direction: column;
        align-items: flex-start;
    }

    #globalSaveSettingsBtn {
        width: 100%;
    }

    .app-card {
        padding: var(--spacing-lg);
    }

    .app-card h3 {
        font-size: 1.2rem;
    }

    .view-header {
        margin-bottom: var(--spacing-md);
    }

    .view-header h2 {
        font-size: 1.375rem;
    }

    .suggestion-card {
        padding: var(--spacing-lg);
    }

    .suggestion-title {
        font-size: 1rem;
    }

    .vote-column {
        width: 40px;
    }

    .upvote-btn {
        padding: 5px 8px;
    }

    .form-actions {
        flex-direction: column-reverse;
        gap: var(--spacing-sm);
    }

    .form-actions .primary-btn,
    .form-actions .secondary-btn {
        width: 100%;
        padding: 12px;
    }

    /* Filter bar: edge-to-edge scroll on mobile */
    .filter-bar {
        margin-left: calc(-1 * var(--spacing-md));
        margin-right: calc(-1 * var(--spacing-md));
        padding-left: var(--spacing-md);
        padding-right: var(--spacing-md);
    }

    .suggestions-topbar {
        position: sticky;
        top: 0;
        z-index: 30;
        margin: 0 calc(-1 * var(--spacing-md)) var(--spacing-lg);
        padding: calc(env(safe-area-inset-top) + var(--spacing-sm)) var(--spacing-md) var(--spacing-md);
        background: var(--sticky-surface);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border-bottom: 1px solid var(--border-light);
        box-shadow: var(--sticky-shadow);
    }

    .suggestions-topbar .view-header {
        gap: var(--spacing-sm);
        align-items: center;
    }

    .suggestions-topbar .view-header h2 {
        flex: 1;
        min-width: 0;
    }

    .mobile-inline-action-btn {
        display: inline-flex;
    }

    .header-action-btn {
        display: none !important;
    }

    .toast {
        top: 60px;
        right: var(--spacing-md);
        left: var(--spacing-md);
        max-width: none;
    }

    .form-group input,
    .form-group textarea {
        padding: 12px 14px;
        font-size: 1rem;
    }

    .overlay {
        padding: var(--spacing-md);
    }

    .overlay-content {
        padding: var(--spacing-xl);
    }

    .overlay-icon {
        width: 60px;
        height: 60px;
        font-size: 1.75rem;
        margin-bottom: var(--spacing-md);
    }

    /* Touch targets */
    button, .back-btn {
        min-height: 44px;
    }
}

/* Small mobile */
@media (max-width: 480px) {
    .container {
        padding: var(--spacing);
    }

    .suggestions-topbar {
        margin-left: calc(-1 * var(--spacing));
        margin-right: calc(-1 * var(--spacing));
        padding-left: var(--spacing);
        padding-right: var(--spacing);
    }

    .header h1 {
        font-size: 1.85rem;
    }

    .filter-bar {
        margin-left: calc(-1 * var(--spacing));
        margin-right: calc(-1 * var(--spacing));
        padding-left: var(--spacing);
        padding-right: var(--spacing);
    }
}

/* Touch devices: no hover effects */
@media (hover: none) {
    .app-card:hover,
    .suggestion-card:hover {
        transform: none;
        box-shadow: var(--shadow);
    }

    .app-card:hover::before {
        opacity: 0;
    }

    .app-card:active {
        transform: scale(0.98);
    }

    .suggestion-card:active {
        background: var(--surface-hover);
    }
}

/* ─── VIEW TABS ────────────────────────────────────────────────────── */

.view-tabs {
    display: flex;
    gap: 4px;
    padding: 4px;
    background: var(--background-alt);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-sm);
}

.view-tab {
    flex: 1;
    padding: 8px 16px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
}

.view-tab:hover {
    color: var(--text-primary);
    background: var(--surface-hover);
}

.view-tab.active {
    background: var(--surface);
    color: var(--text-primary);
    box-shadow: var(--shadow-sm);
}

/* ─── RELEASE VIEWS (Roadmap & Changelog) ──────────────────────────── */

.release-view {
    padding: 0;
}

.release-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: var(--spacing-lg);
    margin-bottom: var(--spacing-md);
    transition: var(--transition);
}

.release-card:hover {
    box-shadow: var(--shadow);
}

.release-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-sm);
    flex-wrap: wrap;
}

.release-header-left {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    flex-wrap: wrap;
}

.release-version {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.release-title-text {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.release-status-badge {
    color: white;
    padding: 3px 10px;
    border-radius: var(--radius);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.release-date {
    color: var(--text-muted);
    font-size: 0.85rem;
    flex-shrink: 0;
}

.release-description {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
    margin: var(--spacing-sm) 0;
    white-space: pre-line;
}

.release-items,
.release-items-grouped {
    margin-top: var(--spacing-md);
    padding-top: var(--spacing-md);
    border-top: 1px solid var(--border-light);
}

.release-type-group {
    margin-bottom: var(--spacing-md);
}

.release-type-group:last-child {
    margin-bottom: 0;
}

.release-group-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 var(--spacing-sm) 0;
}

.release-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: 6px 0;
    font-size: 0.875rem;
    color: var(--text-primary);
}

.release-item-button {
    width: 100%;
    border: 0;
    background: transparent;
    border-radius: var(--radius);
    cursor: pointer;
    font: inherit;
    text-align: left;
    transition: var(--transition);
}

.release-item-button:hover,
.release-item-button:focus-visible {
    background: var(--surface-hover);
    padding-left: var(--spacing-xs);
    padding-right: var(--spacing-xs);
    outline: none;
}

.suggestion-card.is-highlighted {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-glow), var(--shadow);
}

.release-item-icon {
    flex-shrink: 0;
    font-size: 0.9rem;
}

.release-item-title {
    flex: 1;
}

.release-no-items {
    color: var(--text-muted);
    font-size: 0.85rem;
    font-style: italic;
    margin: var(--spacing-sm) 0 0 0;
}

.release-empty {
    text-align: center;
    padding: var(--spacing-xl) var(--spacing-lg);
    color: var(--text-muted);
    font-size: 0.95rem;
}

@media (max-width: 640px) {
    .view-tabs {
        gap: 2px;
    }

    .view-tab {
        padding: 8px 10px;
        font-size: 0.8rem;
    }

    .release-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .release-card {
        padding: var(--spacing-md);
    }
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    body::before {
        animation: none;
    }
}
