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

:root {
    --bg-dark: hsl(0, 0%, 5%);
    --bg-card: hsl(0, 0%, 10%);
    --primary-red: hsl(0, 100%, 50%);
    --text-light: hsl(0, 0%, 100%);
    --text-muted: hsl(0, 0%, 65%);
    --border: hsl(0, 0%, 18%);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-dark);
    color: var(--text-light);
    line-height: 1.6;
}

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

.header {
    background: var(--bg-card);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 2px solid var(--primary-red);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: 'Archivo Black', Impact, sans-serif;
    font-size: 2rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 4px;
    position: relative;
    display: inline-block;
    font-weight: 900;
}

.logo-text {
    position: relative;
    display: inline-block;
    color: var(--text-light);
    text-shadow: 
        -2px -2px 0 var(--bg-dark),
        2px -2px 0 var(--bg-dark),
        -2px 2px 0 var(--bg-dark),
        2px 2px 0 var(--bg-dark),
        0 0 10px var(--primary-red);
    animation: sprayGlow 2s ease-in-out infinite;
}

/* Stencil cutout effect */
.logo-text::before {
    content: attr(data-text);
    position: absolute;
    left: 0;
    top: 0;
    color: transparent;
    -webkit-text-stroke: 2px var(--primary-red);
    z-index: -1;
}

/* Spray paint wave effect */
.logo-text::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 6px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        var(--primary-red) 15%, 
        var(--text-light) 30%, 
        var(--primary-red) 45%, 
        transparent 60%,
        var(--primary-red) 75%,
        transparent 100%
    );
    background-size: 200% 100%;
    animation: waveSlide 3s linear infinite;
    opacity: 0.8;
    filter: blur(1px);
}

@keyframes sprayGlow {
    0%, 100% {
        text-shadow: 
            -2px -2px 0 var(--bg-dark),
            2px -2px 0 var(--bg-dark),
            -2px 2px 0 var(--bg-dark),
            2px 2px 0 var(--bg-dark),
            0 0 10px var(--primary-red);
    }
    50% {
        text-shadow: 
            -2px -2px 0 var(--bg-dark),
            2px -2px 0 var(--bg-dark),
            -2px 2px 0 var(--bg-dark),
            2px 2px 0 var(--bg-dark),
            0 0 20px var(--primary-red),
            0 0 30px rgba(255, 0, 0, 0.5);
    }
}

@keyframes waveSlide {
    0% {
        background-position: 0% 0%;
    }
    100% {
        background-position: 200% 0%;
    }
}

.ad-card {
    min-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: hsl(0, 0%, 10%);
    border: 1px dashed hsl(0, 0%, 20%);
}

.btn-primary {
    background: var(--primary-red);
    color: var(--text-light);
    border: 2px solid var(--primary-red);
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-primary:hover {
    background: transparent;
    color: var(--primary-red);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 0, 0, 0.3);
}

.btn-secondary {
    background: var(--border);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-secondary:hover {
    background: hsl(0, 0%, 30%);
}

.btn-full {
    width: 100%;
}

.masonry-grid {
    column-count: 1;
    column-gap: 20px;
    margin: 30px 0;
}

@media (min-width: 768px) {
    .masonry-grid {
        column-count: 2;
    }
}

@media (min-width: 1024px) {
    .masonry-grid {
        column-count: 3;
    }
}

@media (min-width: 1400px) {
    .masonry-grid {
        column-count: 4;
    }
}

.card {
    background: var(--bg-card);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 20px;
    break-inside: avoid;
    transition: transform 0.2s;
    position: relative;
}

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

.card-image {
    width: 100%;
    display: block;
    cursor: pointer;
}

/* Punk/Rap Style Badges */
.badge {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 6px 12px;
    font-family: 'Archivo Black', Impact, sans-serif;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    z-index: 10;
    transform: rotate(-3deg);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.8);
    border: 2px solid;
    line-height: 1;
}

.badge::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: inherit;
    filter: blur(4px);
    opacity: 0.5;
    z-index: -1;
}

/* Top Picks Badge - Pure White on Black */
.badge-top-picks {
    background: var(--bg-dark);
    color: var(--text-light);
    border-color: var(--text-light);
    text-shadow: 0 0 8px var(--text-light);
}

/* Most Love Badge - Red Hot */
.badge-most-love {
    background: var(--primary-red);
    color: var(--text-light);
    border-color: var(--text-light);
    animation: pulseBadge 1.5s ease-in-out infinite;
}

/* Being Trashed Badge - Warning Red */
.badge-trash-soon {
    background: var(--bg-dark);
    color: var(--primary-red);
    border-color: var(--primary-red);
    text-shadow: 0 0 8px var(--primary-red);
    animation: shake 0.5s ease-in-out infinite;
}

/* NEW Badge - Fresh White */
.badge-new {
    background: var(--text-light);
    color: var(--bg-dark);
    border-color: var(--bg-dark);
    font-style: italic;
}

/* Reported Badge - Yellow Warning */
.badge-reported {
    background: hsl(48, 100%, 50%);
    color: var(--bg-dark);
    border-color: var(--bg-dark);
    text-shadow: 0 0 4px rgba(0, 0, 0, 0.3);
}

@keyframes pulseBadge {
    0%, 100% {
        transform: rotate(-3deg) scale(1);
    }
    50% {
        transform: rotate(-3deg) scale(1.05);
        box-shadow: 0 6px 16px rgba(255, 0, 0, 0.8);
    }
}

@keyframes shake {
    0%, 100% {
        transform: rotate(-3deg) translateX(0);
    }
    25% {
        transform: rotate(-3deg) translateX(-2px);
    }
    75% {
        transform: rotate(-3deg) translateX(2px);
    }
}

.card-content {
    padding: 16px;
}

.card-location {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.card-ad-id {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 11px;
    font-weight: 600;
    color: #00ff00;
    pointer-events: none;
    z-index: 5;
    text-shadow: 0 0 4px rgba(0, 0, 0, 0.8);
}

.card-description {
    font-size: 14px;
    margin-bottom: 12px;
}

.card-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.vote-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-light);
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
}

.vote-btn:hover {
    border-color: var(--text-light);
}

.vote-btn.active-up {
    background: var(--text-light);
    border-color: var(--text-light);
    color: var(--bg-dark);
}

.vote-btn.active-down {
    background: var(--primary-red);
    border-color: var(--primary-red);
    color: var(--text-light);
}

.report-btn {
    background: transparent;
    border: 1px solid hsl(30, 100%, 50%);
    color: hsl(30, 100%, 50%);
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.2s;
    margin-left: auto;
}

.report-btn:hover:not(:disabled) {
    background: hsl(30, 100%, 50%);
    color: var(--bg-dark);
}

.report-btn:disabled {
    cursor: not-allowed;
    border-color: hsl(120, 40%, 50%);
    color: hsl(120, 40%, 50%);
}

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    padding: 20px;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: var(--bg-card);
    padding: 30px;
    border-radius: 12px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.close {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 32px;
    font-weight: bold;
    color: var(--text-muted);
    cursor: pointer;
}

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

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input[type="text"],
.form-group textarea {
    width: 100%;
    padding: 12px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text-light);
    font-size: 14px;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-red);
}

.upload-area {
    position: relative;
    border: 2px dashed var(--border);
    border-radius: 8px;
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s;
}

.upload-area:hover {
    border-color: var(--primary-red);
}

.upload-area input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    opacity: 0;
    cursor: pointer;
}

.upload-placeholder span {
    font-size: 48px;
    display: block;
    margin-bottom: 10px;
}

.upload-placeholder p {
    margin-bottom: 5px;
}

.upload-placeholder small {
    color: var(--text-muted);
}

#imagePreview {
    max-width: 100%;
    border-radius: 8px;
}

.btn-gps {
    background: var(--bg-dark);
    color: var(--text-light);
    border: 1px solid var(--border);
    padding: 10px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    margin-top: 8px;
}

.btn-gps:hover {
    border-color: var(--primary-red);
}

.loading {
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
}

.load-more {
    text-align: center;
    margin: 40px 0;
}

.footer {
    background: var(--bg-card);
    padding: 40px 0;
    margin-top: 60px;
    border-top: 1px solid var(--border);
}

.footer-links {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-bottom: 20px;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
}

.footer-links a:hover {
    color: var(--text-light);
}

.footer p {
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
}

.login-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
}

.login-card {
    background: var(--bg-card);
    padding: 40px;
    border-radius: 12px;
    max-width: 400px;
    width: 100%;
}

.login-card h1 {
    margin-bottom: 20px;
    color: var(--primary-red);
}

.error {
    background: hsl(0, 70%, 30%);
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.success {
    background: hsl(0, 0%, 18%);
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 20px;
    border: 1px solid hsl(0, 100%, 50%);
}

.back-link {
    display: block;
    margin-top: 20px;
    text-align: center;
    color: var(--text-muted);
    text-decoration: none;
}

.back-link:hover {
    color: var(--text-light);
}

.lightbox {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    align-items: center;
    justify-content: center;
}

.lightbox.active {
    display: flex;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 40px;
    color: var(--text-light);
    font-size: 50px;
    font-weight: bold;
    cursor: pointer;
    z-index: 2001;
    transition: color 0.3s;
}

.lightbox-close:hover {
    color: var(--primary-red);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: var(--text-light);
    border: 2px solid var(--border);
    padding: 20px 15px;
    font-size: 24px;
    cursor: pointer;
    z-index: 2001;
    transition: all 0.3s;
}

.lightbox-nav:hover {
    background: var(--primary-red);
    border-color: var(--primary-red);
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-content {
    max-width: 90%;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 60vh;
    object-fit: contain;
    border: 2px solid var(--primary-red);
    box-shadow: 0 0 40px rgba(255, 0, 0, 0.3);
}

.lightbox-info {
    background: var(--bg-card);
    padding: 20px;
    margin-top: 20px;
    border-radius: 8px;
    max-width: 600px;
    width: 100%;
    border: 1px solid var(--border);
}

.lightbox-ad-id {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 11px;
    font-weight: 600;
    color: #00ff00;
    pointer-events: none;
    z-index: 10;
    text-shadow: 0 0 4px rgba(0, 0, 0, 0.8);
}

.lightbox-location {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 10px;
    text-align: center;
}

.lightbox-description {
    font-size: 14px;
    margin-bottom: 10px;
    color: var(--text-light);
    text-align: center;
}

.read-more-link {
    color: var(--primary-red);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}

.read-more-link:hover {
    color: #ff4444;
    text-decoration: underline;
}

.lightbox-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border);
}

.lightbox-votes-row {
    display: flex;
    justify-content: space-between;
    gap: 15px;
}

.lightbox-vote-left,
.lightbox-vote-right {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-light);
    cursor: pointer;
    transition: all 0.3s;
    font-size: 18px;
    font-weight: 600;
}

.lightbox-vote-left:hover,
.lightbox-vote-right:hover {
    transform: translateY(-2px);
}

.upvote-btn:hover {
    background: var(--primary-red);
    border-color: var(--primary-red);
}

.downvote-btn:hover {
    background: hsl(0, 0%, 15%);
    border-color: hsl(0, 0%, 30%);
}

.lightbox-vote-left.voted,
.lightbox-vote-right.voted {
    border-width: 2px;
}

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

.downvote-btn.voted {
    background: hsl(0, 0%, 15%);
    border-color: hsl(0, 0%, 30%);
}

.lightbox-share {
    display: flex;
    align-items: center;
    gap: 12px;
}

.share-label {
    font-weight: 600;
    color: var(--text-light);
}

.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: 50%;
    color: var(--text-light);
    transition: all 0.3s;
    text-decoration: none;
}

.share-btn:hover {
    background: var(--primary-red);
    border-color: var(--primary-red);
    transform: translateY(-2px);
}

.share-btn svg {
    width: 20px;
    height: 20px;
}

.lightbox-report-btn {
    flex: 1;
    padding: 10px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-light);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
}

.lightbox-report-btn:hover {
    background: var(--primary-red);
    border-color: var(--primary-red);
}

.lightbox-report-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

@media (max-width: 768px) {
    .logo {
        font-size: 1.3rem;
        letter-spacing: 2px;
    }
    
    .logo-text::after {
        height: 4px;
        bottom: -6px;
    }
    
    .btn-primary {
        padding: 10px 18px;
        font-size: 14px;
    }
    
    .modal-content {
        padding: 20px;
    }
    
    .lightbox-close {
        top: 10px;
        right: 20px;
        font-size: 40px;
    }
    
    .lightbox-nav {
        padding: 15px 10px;
        font-size: 20px;
    }
    
    .lightbox-prev {
        left: 10px;
    }
    
    .lightbox-next {
        right: 10px;
    }
    
    .lightbox-content {
        max-height: 90vh;
    }
    
    .lightbox-content img {
        max-height: 50vh;
    }
    
    .lightbox-ad-id {
        top: 8px;
        right: 8px;
        font-size: 10px;
    }
    
    .lightbox-votes-row {
        gap: 10px;
    }
    
    .lightbox-vote-left,
    .lightbox-vote-right {
        flex: 1;
        justify-content: center;
        font-size: 16px;
        padding: 8px 12px;
    }
}
