/* Baltimore Team Colors */
:root {
    --ravens-purple: #241773;
    --ravens-purple-light: #2d1f8a;
    --orioles-orange: #DF4601;
    --orioles-red: #9B2C2C;
    --orioles-red-light: #B83232;
    --accent-gold: #FFD700;
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, var(--ravens-purple) 0%, var(--orioles-red) 100%);
    min-height: 100vh;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(155, 44, 44, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(36, 23, 115, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(255, 140, 0, 0.2) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

body::after {
    content: '🦀 🐦 🦀 🐦 🦀';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
    font-size: 2rem;
    opacity: 0.08;
    animation: floatCrabs 20s linear infinite;
    filter: hue-rotate(0deg);
}

@keyframes floatCrabs {
    0% {
        transform: translateY(100vh) rotate(0deg);
    }
    100% {
        transform: translateY(-100px) rotate(360deg);
    }
}

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

/* Header styles */
.header {
    background: linear-gradient(135deg, var(--ravens-purple) 0%, var(--orioles-red) 100%);
    color: white;
    padding: 2rem 0;
    text-align: center;
    box-shadow: 0 8px 32px rgba(36, 23, 115, 0.4);
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '🦀';
    position: absolute;
    top: 10px;
    left: 20px;
    font-size: 2rem;
    animation: crabBounce 2s ease-in-out infinite;
    filter: drop-shadow(0 0 10px var(--ravens-purple));
}

.header::after {
    content: '🐦';
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 2rem;
    animation: crabBounce 2s ease-in-out infinite 1s;
    filter: drop-shadow(0 0 10px var(--orioles-orange));
}

.logo {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.tagline {
    font-size: 1.2rem;
    opacity: 0.9;
    font-weight: 400;
}

/* Main content */
.main {
    padding: 3rem 0;
    flex: 1;
}

.main-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    align-items: start;
}

.content-section {
    width: 100%;
}

/* Ad Placements */
.ad-banner-header,
.ad-banner-footer {
    background: rgba(255, 255, 255, 0.1);
    padding: 1rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.ad-banner-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    border-bottom: none;
}

.ad-placeholder {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 1rem;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.ad-label {
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 0.5rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ad-content {
    min-height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 10px;
    border: 2px dashed #dee2e6;
}

.ad-content::before {
    content: 'Ad Space';
    color: #6c757d;
    font-size: 0.9rem;
    font-style: italic;
}

/* Sidebar Ad */
.sidebar-ad {
    position: sticky;
    top: 2rem;
}

.sidebar-ad .ad-placeholder {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
}

.sidebar-ad .ad-content {
    min-height: 600px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.sidebar-ad .ad-content::before {
    content: 'Sidebar Ad Space';
    color: #6c757d;
    font-size: 0.9rem;
    font-style: italic;
}

/* Inline Ad */
.inline-ad {
    margin: 2rem 0;
}

.inline-ad .ad-content {
    min-height: 120px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.inline-ad .ad-content::before {
    content: 'Inline Ad Space';
    color: #6c757d;
    font-size: 0.9rem;
    font-style: italic;
}

/* Responsive design for ads */
@media (max-width: 1024px) {
    .main-content-wrapper {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .sidebar-ad {
        position: static;
        order: -1;
    }
    
    .sidebar-ad .ad-content {
        min-height: 250px;
    }
}

@media (max-width: 768px) {
    .ad-banner-header,
    .ad-banner-footer {
        padding: 0.5rem 0;
    }
    
    .ad-placeholder {
        padding: 0.5rem;
    }
    
    .ad-content {
        min-height: 60px;
    }
    
    .sidebar-ad .ad-content {
        min-height: 200px;
    }
}

.controls {
    text-align: center;
    margin-bottom: 2rem;
}

.btn {
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 0 0.5rem;
    font-family: inherit;
}

.btn-primary {
    background: linear-gradient(135deg, var(--ravens-purple) 0%, var(--orioles-red) 100%);
    color: white;
    box-shadow: 0 8px 25px rgba(36, 23, 115, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.6);
}

.btn-secondary {
    background: linear-gradient(135deg, var(--orioles-orange) 0%, var(--accent-gold) 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(223, 70, 1, 0.4);
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(78, 205, 196, 0.6);
}

/* Content card */
.content-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 25px;
    padding: 2rem;
    margin: 2rem 0;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    transition: all 0.4s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.content-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
}

.content-placeholder {
    color: #666;
    font-size: 1.2rem;
}

.meme-content {
    width: 100%;
}

.meme-text {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 1rem;
    line-height: 1.4;
}

.meme-image {
    max-width: 100%;
    height: auto;
    border-radius: 20px;
    margin: 1.5rem 0;
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
    transition: transform 0.3s ease;
    border: 3px solid var(--ravens-purple);
}

.meme-image:hover {
    transform: scale(1.02);
    box-shadow: 0 20px 45px rgba(0,0,0,0.3);
}

.meme-caption {
    font-size: 1rem;
    color: #666;
    font-style: italic;
    margin-top: 1rem;
}

/* Stats */
.stats {
    text-align: center;
    color: #666;
    font-size: 0.9rem;
}

/* API Status */
.api-status {
    text-align: center;
    margin: 1rem 0;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    color: white;
    font-size: 0.9rem;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.api-status.loaded {
    background: rgba(76, 175, 80, 0.2);
    border-color: rgba(76, 175, 80, 0.3);
}

.api-status.error {
    background: rgba(244, 67, 54, 0.2);
    border-color: rgba(244, 67, 54, 0.3);
}

/* Quotes Section */
.quotes-section {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 25px;
    padding: 2rem;
    margin: 2rem 0;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.quotes-section h3 {
    text-align: center;
    color: var(--ravens-purple);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    font-weight: 700;
}

.quotes-container {
    text-align: center;
}

.quote-placeholder {
    color: #666;
    font-style: italic;
    font-size: 1.1rem;
}

.quote-item {
    background: linear-gradient(135deg, var(--ravens-purple) 0%, var(--orioles-red) 100%);
    color: white;
    padding: 1.5rem;
    margin: 1rem 0;
    border-radius: 15px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.quote-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(0,0,0,0.15);
}

.quote-text {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.quote-category {
    font-size: 0.9rem;
    opacity: 0.8;
    font-style: italic;
}

/* Team indicators for sports content */
.team-indicator {
    background: linear-gradient(135deg, var(--ravens-purple), var(--orioles-red));
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: bold;
    text-align: center;
    margin: 10px 0;
    font-size: 14px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* Enhanced Reddit content info */
.reddit-info {
    background: rgba(255, 69, 0, 0.1);
    border-left: 4px solid #ff4500;
    padding: 8px 12px;
    margin: 10px 0;
    font-size: 12px;
    color: #666;
    border-radius: 0 8px 8px 0;
}

.reddit-info::before {
    content: '🔗 ';
    margin-right: 4px;
}

/* Enhanced meme category display */
.meme-category {
    background: linear-gradient(135deg, var(--ravens-purple), var(--orioles-red));
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: bold;
    text-align: center;
    margin: 10px 0;
    font-size: 14px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    display: inline-block;
}

/* Content source badges */
.content-source {
    display: inline-block;
    background: rgba(0,0,0,0.1);
    color: #666;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    margin: 4px 4px 4px 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.content-source.reddit {
    background: rgba(255, 69, 0, 0.1);
    color: #ff4500;
    border: 1px solid rgba(255, 69, 0, 0.3);
}

.content-source.unsplash {
    background: rgba(0, 0, 0, 0.1);
    color: #333;
    border: 1px solid rgba(0, 0, 0, 0.2);
}

.content-source.fallback {
    background: rgba(76, 175, 80, 0.1);
    color: #4caf50;
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.meme-credit {
    font-size: 0.8rem;
    color: #666;
    margin-top: 0.5rem;
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.meme-credit a {
    color: var(--ravens-purple);
    text-decoration: none;
    font-weight: 600;
}

.meme-credit a:hover {
    text-decoration: underline;
    color: var(--orioles-red);
}

/* Fallback Indicator */
.fallback-indicator {
    background: linear-gradient(135deg, var(--ravens-purple) 0%, var(--orioles-red) 100%);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-top: 0.5rem;
    display: inline-block;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Image Error Handling */
.meme-image[src*="data:image/svg+xml"] {
    background: #f8f9fa;
    border: 2px dashed #dee2e6 !important;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    font-family: 'Inter', sans-serif;
    color: #6c757d;
}

/* Footer */
.footer {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: white;
    text-align: center;
    padding: 2rem 0;
    margin-top: auto;
    position: relative;
}

.footer::before {
    content: '🦀 🐦 🦀';
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1.5rem;
    opacity: 0.7;
    filter: drop-shadow(0 0 5px var(--accent-gold));
}

.footer a {
    color: #3498db;
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes crabBounce {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-10px) rotate(5deg);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

/* Responsive design */
@media (max-width: 768px) {
    .logo {
        font-size: 2rem;
    }
    
    .tagline {
        font-size: 1rem;
    }
    
    .btn {
        display: block;
        width: 100%;
        margin: 0.5rem 0;
    }
    
    .content-card {
        padding: 1.5rem;
        margin: 1rem 0;
    }
    
    .meme-text {
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .header {
        padding: 1.5rem 0;
    }
    
    .main {
        padding: 2rem 0;
    }
}
