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

:root {
    --dark-bg: #0f0f1e;
    --darker-bg: #1a1a2e;
    --accent: #ff6b9d;
    --accent-light: #ff8fb3;
    --text-light: #e0e0e0;
    --text-lighter: #f0f0f0;
    --border-color: #333344;
    --success: #4ade80;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Fredoka', sans-serif;
    background-color: var(--dark-bg);
    color: var(--text-light);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header and Navigation */
.header {
    background-color: var(--darker-bg);
    border-bottom: 3px solid var(--accent);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.logo h1 {
    font-family: 'Bangers', cursive;
    font-size: clamp(1.8rem, 5vw, 2.5rem);
    color: var(--accent);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7),
                 -1px -1px 0 rgba(255, 255, 255, 0.1);
    letter-spacing: 1px;
    transform: skew(-5deg);
}

.nav {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: var(--accent);
    background-color: rgba(255, 107, 157, 0.1);
}

.nav-link.active {
    color: var(--accent);
    border-bottom: 2px solid var(--accent);
}

/* Tagline Bar */
.tagline-bar {
    background-color: var(--darker-bg);
    text-align: center;
    padding: 1.2rem 1.5rem;
}

.tagline-bar p {
    font-family: 'Bangers', cursive;
    font-size: 2.2rem;
    color: var(--text-lighter);
    margin: 0;
    letter-spacing: 2px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.4);
}

@media (max-width: 768px) {
    .tagline-bar p { font-size: 1.5rem; }
}

@media (max-width: 480px) {
    .tagline-bar p { font-size: 1.2rem; }
}

/* Latest Comics Banner (Penny Arcade-inspired) */
.latest-banner {
    background: linear-gradient(135deg, var(--accent) 0%, #e0457b 100%);
    padding: 0;
    overflow: hidden;
}

.latest-banner-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: stretch;
    min-height: 180px;
}

.latest-banner-label {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 1.5rem 2rem;
    min-width: 200px;
    flex-shrink: 0;
}

.latest-label-big {
    font-family: 'Bangers', cursive;
    font-size: 2.8rem;
    color: white;
    line-height: 1;
    letter-spacing: 2px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.latest-label-sub {
    font-family: 'Fredoka', sans-serif;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 700;
    letter-spacing: 1.5px;
    margin-top: 0.5rem;
    text-transform: uppercase;
}

.latest-banner-cards {
    display: flex;
    flex: 1;
    gap: 4px;
    overflow: hidden;
}

.latest-banner-card {
    flex: 1;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    text-decoration: none;
    display: block;
    min-height: 180px;
}

.latest-banner-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.latest-banner-card:hover img {
    transform: scale(1.05);
}

.latest-banner-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60%;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.6));
    pointer-events: none;
}

.latest-banner-date {
    position: absolute;
    bottom: 12px;
    right: 16px;
    z-index: 2;
    text-align: right;
    line-height: 1;
}

.latest-banner-day {
    display: block;
    font-family: 'Bangers', cursive;
    font-size: 1.6rem;
    color: white;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    letter-spacing: 1px;
}

.latest-banner-monthday {
    display: block;
    font-family: 'Bangers', cursive;
    font-size: 2.4rem;
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
    letter-spacing: 1px;
}

.latest-banner-title {
    position: absolute;
    bottom: 12px;
    left: 12px;
    z-index: 2;
    font-family: 'Fredoka', sans-serif;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
    max-width: 60%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Banner responsive */
@media (max-width: 768px) {
    .latest-banner-content {
        flex-direction: column;
        min-height: auto;
    }

    .latest-banner-label {
        flex-direction: row;
        align-items: baseline;
        gap: 0.5rem;
        padding: 1rem 1.5rem;
        min-width: auto;
    }

    .latest-label-big { font-size: 1.8rem; }
    .latest-label-sub { margin-top: 0; font-size: 0.65rem; }
    .latest-banner-cards { gap: 2px; }
    .latest-banner-card { min-height: 120px; }
    .latest-banner-day { font-size: 1.1rem; }
    .latest-banner-monthday { font-size: 1.6rem; }
    .latest-banner-title { font-size: 0.7rem; }
}

@media (max-width: 480px) {
    .latest-banner-card { min-height: 100px; }
    .latest-banner-day { font-size: 0.9rem; }
    .latest-banner-monthday { font-size: 1.3rem; }
    .latest-banner-title { display: none; }
}

/* Main Container */
.container {
    flex: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    width: 100%;
}

/* Comic Viewer Section */
.comic-viewer {
    background-color: var(--darker-bg);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 3rem;
    border: 2px solid var(--accent);
    box-shadow: 0 8px 24px rgba(255, 107, 157, 0.15);
}

.comic-display {
    margin-bottom: 2rem;
}

.comic-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.comic-header h2 {
    font-size: 1.8rem;
    color: var(--accent-light);
    margin-bottom: 0.5rem;
    font-family: 'Bangers', cursive;
}

.comic-date {
    color: #888;
    font-size: 0.9rem;
    font-style: italic;
}

/* Comic Panels Container */
.comic-panels {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 2rem 0;
    gap: 0;
}

/* Desktop: horizontal layout */
.comic-panels.panels-1 {
    /* Single panel: just center it */
}

.comic-panels.panels-2 {
    flex-direction: row;
}

.comic-panels.panels-3 {
    flex-direction: row;
}

.comic-panels.panels-4 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
}

.comic-panels .panel-img {
    width: 100%;
    height: auto;
    display: block;
}

/* For row layouts, panels share width equally */
.comic-panels.panels-2 .panel-img,
.comic-panels.panels-3 .panel-img {
    flex: 1;
    min-width: 0;
}

.comic-description {
    text-align: center;
    color: #aaa;
    font-size: 0.95rem;
    margin-top: 1rem;
    font-style: italic;
}

/* Comic Navigation */
.comic-navigation {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    padding: 1.5rem;
    background-color: rgba(255, 107, 157, 0.05);
    border-radius: 8px;
}

.nav-btn {
    background-color: var(--accent);
    color: white;
    border: none;
    padding: 0.7rem 1.2rem;
    border-radius: 6px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
}

.nav-btn:hover {
    background-color: var(--accent-light);
    transform: scale(1.08);
    box-shadow: 0 4px 12px rgba(255, 107, 157, 0.4);
}

.nav-btn:active {
    transform: scale(0.95);
}

.nav-btn:disabled {
    background-color: #555;
    cursor: not-allowed;
    opacity: 0.5;
}

.nav-btn .icon {
    font-size: 1.2rem;
}

.nav-icon {
    width: 20px;
    height: 20px;
}

.comic-counter {
    font-weight: 600;
    color: var(--text-lighter);
    min-width: 60px;
    text-align: center;
}

/* Random Comic Button */
.random-section {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
}

.btn-random {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #ff6b9d 0%, #c850c0 50%, #6c63ff 100%);
    color: white;
    border: none;
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 700;
    font-family: 'Bangers', cursive;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(200, 80, 192, 0.3);
}

.btn-random:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 20px rgba(200, 80, 192, 0.5);
}

.btn-random:active {
    transform: scale(0.95);
}

.random-icon {
    font-size: 1.3rem;
}

/* Panel count badge on cards */
.panel-badge {
    display: inline-block;
    background: var(--accent);
    color: white;
    font-size: 0.65rem;
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

/* Recent Comics Section */
.recent-comics {
    margin-bottom: 3rem;
}

.recent-comics h2 {
    font-size: 1.8rem;
    color: var(--accent-light);
    margin-bottom: 1.5rem;
    font-family: 'Bangers', cursive;
}

.comics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
}

.comic-card {
    background-color: var(--darker-bg);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.comic-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent);
    box-shadow: 0 8px 20px rgba(255, 107, 157, 0.3);
}

.comic-card-image {
    width: 100%;
    height: 200px;
    background-color: rgba(255, 107, 157, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.comic-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.comic-card-info {
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.comic-card-title {
    font-weight: 600;
    color: var(--accent-light);
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.comic-card-date {
    font-size: 0.85rem;
    color: #888;
}

/* About Section */
.about-section,
.tips-section {
    background-color: var(--darker-bg);
    border-radius: 12px;
    padding: 2.5rem;
    border: 2px solid var(--accent);
    box-shadow: 0 8px 24px rgba(255, 107, 157, 0.15);
}

.about-content,
.tips-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-header,
.tips-header {
    text-align: center;
    margin-bottom: 2rem;
}

.about-header h2,
.tips-header h2 {
    font-size: 2rem;
    color: var(--accent-light);
    margin-bottom: 0.5rem;
    font-family: 'Bangers', cursive;
}

.tagline {
    color: #aaa;
    font-size: 1.1rem;
    font-style: italic;
}

.about-body,
.tips-body {
    color: var(--text-light);
    line-height: 1.8;
}

.about-body p,
.tips-body p {
    margin-bottom: 1.5rem;
    text-align: justify;
}

.social-section {
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.social-section h3 {
    color: var(--accent-light);
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
}

.social-links {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.social-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background-color: rgba(255, 107, 157, 0.1);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-light);
    transition: all 0.3s ease;
    min-width: 180px;
}

.social-card:hover {
    border-color: var(--accent);
    background-color: rgba(255, 107, 157, 0.15);
    transform: translateY(-4px);
}

.social-emoji {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.social-name {
    font-weight: 600;
    color: var(--accent-light);
}

.social-handle {
    font-size: 0.85rem;
    color: #888;
    margin-top: 0.3rem;
}

/* Instagram SVG Icons */
.instagram-svg {
    display: block;
}

.instagram-svg-large {
    color: var(--accent);
    margin-bottom: 0.5rem;
}

.social-card:hover .instagram-svg-large {
    color: var(--accent-light);
}

.instagram-svg-btn {
    vertical-align: middle;
    margin-right: 0.3rem;
}

.btn-instagram {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

/* Support Options */
.support-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.support-option {
    background-color: rgba(255, 107, 157, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.support-option:hover {
    border-color: var(--accent);
    background-color: rgba(255, 107, 157, 0.1);
}

.support-option h3 {
    color: var(--accent-light);
    margin-bottom: 1rem;
}

.support-option p {
    color: var(--text-light);
    margin-bottom: 1rem;
    text-align: left;
}

.gratitude {
    background-color: rgba(74, 222, 128, 0.1);
    border: 2px solid var(--success);
    border-radius: 8px;
    padding: 1.5rem;
    margin-top: 2rem;
    text-align: center;
    color: var(--success);
}

.gratitude p {
    margin: 0;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
}

.btn-primary {
    background-color: var(--accent);
    color: white;
}

.btn-primary:hover {
    background-color: var(--accent-light);
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(255, 107, 157, 0.4);
}

.btn-secondary {
    background-color: transparent;
    color: var(--accent);
    border: 2px solid var(--accent);
}

.btn-secondary:hover {
    background-color: var(--accent);
    color: white;
}

/* Footer */
.footer {
    background-color: var(--darker-bg);
    border-top: 3px solid var(--accent);
    padding: 2rem 1.5rem;
    text-align: center;
    margin-top: auto;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.footer-content p {
    margin: 0;
    color: #888;
    font-size: 0.9rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background-color: rgba(255, 107, 157, 0.1);
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s ease;
    color: var(--accent);
}

.social-link:hover {
    background-color: var(--accent);
    color: white;
    transform: scale(1.1);
}

.instagram-icon {
    font-size: 1.5rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }

    .nav {
        gap: 1rem;
        width: 100%;
        justify-content: center;
    }

    .nav-link {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
    }

    .container {
        padding: 1rem;
    }

    .comic-viewer {
        padding: 1.5rem;
    }

    .about-section,
    .tips-section {
        padding: 1.5rem;
    }

    .comics-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 1rem;
    }

    .comic-header h2 {
        font-size: 1.4rem;
    }

    /* Mobile: panels stacked vertically, edge-to-edge */
    .comic-panels,
    .comic-panels.panels-2,
    .comic-panels.panels-3 {
        flex-direction: column;
        margin: 1rem -1.5rem;
        gap: 0;
    }

    .comic-panels.panels-4 {
        display: flex;
        flex-direction: column;
        margin: 1rem -1.5rem;
        gap: 0;
    }

    .comic-panels .panel-img {
        width: 100%;
        border-radius: 0;
    }

    .about-header h2,
    .tips-header h2 {
        font-size: 1.5rem;
    }

    .comic-navigation {
        gap: 0.5rem;
    }

    .nav-btn {
        padding: 0.6rem 0.8rem;
        min-width: 40px;
        min-height: 40px;
    }

    .comic-counter {
        min-width: 50px;
        font-size: 0.9rem;
    }

    .support-options {
        grid-template-columns: 1fr;
    }

    .footer-content {
        flex-direction: column;
        gap: 1rem;
    }
}

@media (max-width: 480px) {
    .logo h1 {
        font-size: 1.5rem;
    }

    .nav {
        gap: 0.5rem;
    }

    .nav-link {
        padding: 0.3rem 0.6rem;
        font-size: 0.75rem;
    }

    .comics-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }

    .comic-card-image {
        height: 150px;
    }

    .about-body p,
    .tips-body p {
        text-align: left;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
}

/* Gallery Page */
.gallery-section {
    padding: 2rem 0;
}

.gallery-section h2 {
    font-family: 'Bangers', cursive;
    font-size: 2.5rem;
    color: var(--accent);
    margin-bottom: 2rem;
    letter-spacing: 2px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.gallery-item {
    display: block;
    background: var(--darker-bg);
    border-radius: 8px;
    overflow: hidden;
    text-decoration: none;
    color: var(--text-light);
    border: 2px solid var(--border-color);
    transition: border-color 0.3s, transform 0.3s;
}

.gallery-item:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
}

.gallery-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.gallery-item-info {
    padding: 0.75rem;
}

.gallery-item-info h3 {
    font-family: 'Fredoka', sans-serif;
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--text-light);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Merch Page */
.merch-section {
    padding: 2rem 0;
}

.merch-content {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.merch-header h2 {
    font-family: 'Bangers', cursive;
    font-size: 2.5rem;
    color: var(--accent);
    letter-spacing: 2px;
}

.merch-header .tagline {
    color: var(--text-light);
    font-size: 1.1rem;
    margin-top: 0.5rem;
    margin-bottom: 2rem;
}

.merch-body p {
    color: var(--text-light);
    font-size: 1rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.merch-cta {
    margin: 2rem 0;
}

.merch-cta .btn {
    font-size: 1.1rem;
    padding: 1rem 2rem;
}

.merch-note {
    font-size: 0.9rem;
    color: #888;
    font-style: italic;
}
