/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Source Serif Pro', Georgia, serif;
    background-color: #f5f5dc;
    color: #2c2c2c;
    line-height: 1.6;
    background-image: 
        radial-gradient(circle at 25% 25%, rgba(0,0,0,0.02) 1px, transparent 1px),
        radial-gradient(circle at 75% 75%, rgba(0,0,0,0.02) 1px, transparent 1px);
    background-size: 50px 50px;
}

/* Newspaper Container */
.newspaper-container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: #fff;
    box-shadow: 0 0 20px rgba(0,0,0,0.3);
    border: 2px solid #000;
}

/* Header Styles */
.newspaper-header {
    background: linear-gradient(135deg, #1a1a1a 0%, #333 100%);
    color: #fff;
    padding: 20px;
    border-bottom: 3px solid #000;
}

.masthead {
    text-align: center;
}

.paper-title {
    font-family: 'Playfair Display', serif;
    font-size: 4rem;
    font-weight: 900;
    text-shadow: 3px 3px 0px #000;
    letter-spacing: 4px;
    margin-bottom: 10px;
    background: linear-gradient(45deg, #ffd700, #ffed4e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    font-size: 1.2rem;
    font-style: italic;
    margin-bottom: 15px;
    color: #ccc;
}

.date-line {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    border-top: 1px solid #666;
    padding-top: 10px;
    color: #aaa;
}

/* Music Player */
.music-player {
    background: linear-gradient(135deg, #2c1810, #4a2c1a);
    border: 3px solid #8B4513;
    border-radius: 10px;
    padding: 20px;
    margin-top: 20px;
    text-align: center;
    box-shadow: 5px 5px 0px #333;
    position: relative;
}

.music-player::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    background: repeating-linear-gradient(
        45deg,
        #8B4513,
        #8B4513 2px,
        transparent 2px,
        transparent 4px
    );
    border-radius: 12px;
    z-index: -1;
}

.music-player h3 {
    color: #ffd700;
    font-family: 'Playfair Display', serif;
    font-size: 1.2rem;
    margin-bottom: 15px;
    text-shadow: 2px 2px 0px #000;
    animation: radioGlow 2s ease-in-out infinite alternate;
}

@keyframes radioGlow {
    from { text-shadow: 2px 2px 0px #000, 0 0 5px #ffd700; }
    to { text-shadow: 2px 2px 0px #000, 0 0 20px #ffd700, 0 0 30px #ffd700; }
}

.music-player audio {
    width: 100%;
    max-width: 400px;
    margin: 10px 0;
    border-radius: 8px;
    background: #1a1a1a;
}

.music-player audio::-webkit-media-controls-panel {
    background: linear-gradient(135deg, #2c1810, #4a2c1a);
}

.music-player audio::-webkit-media-controls-play-button {
    background: #ffd700;
    border-radius: 50%;
}

.music-info {
    color: #ccc;
    font-style: italic;
    font-size: 0.9rem;
    margin-top: 10px;
    font-family: 'Source Serif Pro', serif;
}

/* Main Content */
.newspaper-content {
    padding: 30px;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
}

/* Lead Story */
.lead-story {
    grid-column: 1;
}

.headline {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 20px;
    color: #000;
    text-shadow: 2px 2px 0px #ccc;
    border-bottom: 3px solid #000;
    padding-bottom: 10px;
}

.story-text {
    font-size: 1.1rem;
    text-align: justify;
    margin-top: 20px;
    column-count: 2;
    column-gap: 30px;
    column-rule: 1px solid #ddd;
}

/* Comic Panel Styles */
.comic-panel {
    border: 3px solid #000;
    background: #fff;
    padding: 15px;
    margin: 20px 0;
    box-shadow: 5px 5px 0px #333;
    position: relative;
}

.comic-panel::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    background: repeating-linear-gradient(
        45deg,
        #000,
        #000 2px,
        transparent 2px,
        transparent 4px
    );
    z-index: -1;
}

.main-comic {
    grid-column: 1;
    margin-bottom: 30px;
}

.small-comic {
    margin-bottom: 20px;
}

.comic-image {
    width: 100%;
    height: auto;
    border: 2px solid #000;
    background: #f9f9f9;
    display: block;
}

.comic-caption {
    font-family: 'Playfair Display', serif;
    font-size: 0.9rem;
    font-style: italic;
    text-align: center;
    margin-top: 10px;
    padding: 5px;
    background: #f0f0f0;
    border: 1px solid #ccc;
}

/* Sidebar */
.sidebar {
    grid-column: 2;
}

.sidebar-story {
    margin-bottom: 30px;
    padding: 20px;
    border: 2px solid #000;
    background: #fafafa;
}

.sidebar-headline {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 15px;
    color: #000;
    border-bottom: 2px solid #000;
    padding-bottom: 5px;
}

/* Comic Strip Section */
.comic-strip-section {
    grid-column: 1 / -1;
    margin-top: 40px;
    padding: 30px;
    background: #f8f8f8;
    border: 3px solid #000;
}

.comic-navigation {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
    padding: 15px;
    background: #fff;
    border: 2px solid #000;
    border-radius: 8px;
}

.nav-btn {
    background: #333;
    color: #fff;
    border: 2px solid #000;
    padding: 10px 20px;
    font-family: 'Playfair Display', serif;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 5px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    user-select: none;
}

.nav-btn:hover {
    background: #555;
    transform: translateY(-2px);
    box-shadow: 3px 3px 0px #333;
}

.nav-btn:active {
    transform: translateY(0px);
    box-shadow: 1px 1px 0px #333;
}

.nav-btn:focus {
    outline: 2px solid #ffd700;
    outline-offset: 2px;
}

.comic-counter {
    font-family: 'Playfair Display', serif;
    font-weight: bold;
    font-size: 1.1rem;
    color: #333;
    padding: 10px 20px;
    background: #f0f0f0;
    border: 1px solid #ccc;
    border-radius: 5px;
}

.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 30px;
    text-transform: uppercase;
    color: #000;
    text-shadow: 2px 2px 0px #ccc;
}

.comic-strip {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    overflow-x: auto;
    padding: 20px 0;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
}

.comic-strip::-webkit-scrollbar {
    height: 8px;
}

.comic-strip::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.comic-strip::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.comic-strip::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.strip-panel {
    flex: 0 0 auto;
    text-align: center;
    position: relative;
    min-width: 120px;
    max-width: 150px;
    transition: all 0.3s ease;
    scroll-snap-align: start;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.strip-panel:hover {
    transform: scale(1.05);
    z-index: 10;
}

.strip-image {
    width: 100%;
    height: auto;
    border: 2px solid #000;
    background: #fff;
}

.speech-bubble {
    background: #fff;
    border: 2px solid #000;
    padding: 8px 12px;
    margin-top: 10px;
    border-radius: 15px;
    position: relative;
    font-weight: bold;
    font-size: 0.9rem;
}

.speech-bubble::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid #000;
}

.speech-bubble::after {
    content: '';
    position: absolute;
    top: -5px;
    left: 22px;
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-bottom: 6px solid #fff;
}

/* Classifieds */
.classifieds {
    grid-column: 1 / -1;
    margin-top: 40px;
    padding: 30px;
    background: #f0f0f0;
    border: 2px solid #000;
}

.ad-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.ad-item {
    background: #fff;
    padding: 20px;
    border: 2px solid #000;
    box-shadow: 3px 3px 0px #333;
}

.ad-item h4 {
    font-family: 'Playfair Display', serif;
    font-size: 1.2rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 10px;
    color: #000;
    border-bottom: 1px solid #000;
    padding-bottom: 5px;
}

.ad-item p {
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Weather Section */
.weather-section {
    grid-column: 1 / -1;
    margin-top: 40px;
    padding: 30px;
    background: linear-gradient(135deg, #87ceeb, #98d8e8);
    border: 3px solid #000;
}

.weather-content {
    display: flex;
    justify-content: space-around;
    gap: 30px;
    margin-top: 20px;
}

.weather-panel {
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(255, 255, 255, 0.9);
    padding: 20px;
    border: 2px solid #000;
    box-shadow: 3px 3px 0px #333;
}

.weather-icon {
    width: 80px;
    height: 80px;
    border: 2px solid #000;
    background: #fff;
}

.weather-info h4 {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 5px;
    color: #000;
}

.weather-info p {
    font-size: 0.9rem;
    color: #333;
}

/* Footer */
.newspaper-footer {
    background: #1a1a1a;
    color: #fff;
    padding: 20px;
    text-align: center;
    border-top: 3px solid #000;
}

.footer-content p {
    margin-bottom: 5px;
    font-size: 0.8rem;
    color: #ccc;
}

/* Responsive Design */
@media (max-width: 768px) {
    .newspaper-content {
        grid-template-columns: 1fr;
        padding: 15px;
    }
    
    .paper-title {
        font-size: 2.5rem;
        letter-spacing: 2px;
    }
    
    .headline {
        font-size: 1.8rem;
    }
    
    .story-text {
        column-count: 1;
        font-size: 1rem;
    }
    
    .comic-strip {
        flex-direction: row;
        gap: 10px;
        padding: 15px 0;
    }
    
    .strip-panel {
        min-width: 100px;
        max-width: 120px;
    }
    
    .speech-bubble {
        font-size: 0.8rem;
        padding: 6px 10px;
    }
    
    .comic-navigation {
        flex-direction: column;
        gap: 15px;
        padding: 20px;
    }
    
    .nav-btn {
        padding: 15px 25px;
        font-size: 1.1rem;
        min-width: 120px;
    }
    
    .comic-counter {
        font-size: 1rem;
        padding: 12px 20px;
    }
    
    .weather-content {
        flex-direction: column;
    }
    
    .date-line {
        flex-direction: column;
        gap: 5px;
    }
    
    .section-title {
        font-size: 1.5rem;
        margin-bottom: 20px;
    }
    
    .comic-strip-section {
        padding: 20px 15px;
        margin-top: 30px;
    }
    
    .ad-grid {
        grid-template-columns: 1fr;
    }
    
    .weather-panel {
        flex-direction: column;
        text-align: center;
    }
    
    .weather-icon {
        width: 60px;
        height: 60px;
    }
}

/* Extra small mobile devices */
@media (max-width: 480px) {
    .newspaper-content {
        padding: 10px;
    }
    
    .paper-title {
        font-size: 2rem;
        letter-spacing: 1px;
    }
    
    .headline {
        font-size: 1.4rem;
    }
    
    .comic-strip {
        gap: 8px;
        padding: 10px 0;
    }
    
    .strip-panel {
        min-width: 80px;
        max-width: 100px;
    }
    
    .speech-bubble {
        font-size: 0.7rem;
        padding: 4px 8px;
        margin-top: 8px;
    }
    
    .nav-btn {
        padding: 12px 20px;
        font-size: 1rem;
        min-width: 100px;
    }
    
    .comic-counter {
        font-size: 0.9rem;
        padding: 10px 15px;
    }
    
    .section-title {
        font-size: 1.3rem;
    }
    
    .comic-strip-section {
        padding: 15px 10px;
    }
    
    .comic-navigation {
        padding: 15px;
        gap: 10px;
    }
    
    .music-player {
        padding: 15px;
        margin-top: 15px;
    }
    
    .music-player h3 {
        font-size: 1rem;
    }
    
    .music-player audio {
        max-width: 100%;
    }
}

/* Vintage Effects */
.newspaper-container::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(120, 219, 255, 0.3) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

/* Hover Effects */
.comic-panel:hover {
    transform: translateY(-2px);
    box-shadow: 7px 7px 0px #333;
    transition: all 0.3s ease;
}

.ad-item:hover {
    transform: translateY(-2px);
    box-shadow: 5px 5px 0px #333;
    transition: all 0.3s ease;
}

/* Print Styles */
@media print {
    body {
        background: white;
    }
    
    .newspaper-container {
        box-shadow: none;
        border: 1px solid #000;
    }
    
    .comic-panel::before {
        display: none;
    }
}
