/* 1.89.studio - Dark Theme with Pink/Yellow accents */
@import url('https://fonts.googleapis.com/css2?family=Bungee+Shade&family=Inter:wght@400;500;700&display=swap');

:root {
    --yellow: #FFE135;
    --pink: #E91E8C;
    --white: #fff;
    --gray: rgba(255, 255, 255, 0.6);
    --dark: #000;
}

/* Animated gradient for display text */
@keyframes gradient-shift {
    0% { background-position: 0% center; }
    50% { background-position: 100% center; }
    100% { background-position: 0% center; }
}

.gradient-text {
    background: linear-gradient(90deg, var(--yellow), var(--pink), var(--yellow));
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 3s ease infinite;
}

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

body {
    font-family: var(--gh-font-body, 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif);
    line-height: 1.6;
    background: transparent;
    color: var(--white);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--gh-font-heading, 'Bungee Shade', cursive);
}

/* Hero 3D Canvas */
.hero-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    background: var(--dark);
}

.hero-canvas canvas {
    display: block;
}

/* Ensure content sits above hero */
.site-header,
main,
.site-footer {
    position: relative;
    z-index: 1;
}

/* Header */
.site-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem;
    background: transparent;
    border-bottom: none;
}

.site-logo,
.site-nav a {
    font-family: 'Bungee Shade', cursive;
    text-decoration: none;
    background: linear-gradient(90deg, var(--yellow), var(--pink), var(--yellow));
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 3s ease infinite;
    transition: filter 0.2s ease;
}

.site-logo:hover,
.site-nav a:hover {
    filter: drop-shadow(0 0 8px var(--pink)) drop-shadow(0 0 16px rgba(233, 30, 140, 0.5));
}

.site-logo {
    font-size: 1.5rem;
    font-weight: 400;
}

.site-nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
}

/* Mobile nav toggle */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 100;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--pink);
    margin: 5px 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Hero spacer - pushes content below 3D hero */
.hero-spacer {
    height: 90vh;
}

/* Gallery grid */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 0;
    background: var(--dark);
}

.gallery-item {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 4/3;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.gallery-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-overlay h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    transition: filter 0.2s ease;
}

.gallery-item:hover .gallery-overlay h2 {
    filter: drop-shadow(0 0 8px var(--pink)) drop-shadow(0 0 16px rgba(233, 30, 140, 0.5));
}

.gallery-overlay p {
    color: var(--white);
    font-size: 0.9rem;
}

/* Main content */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* Single post/page */
.post,
.page {
    max-width: 800px;
    margin: 0 auto;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    padding: 3rem;
    border-radius: 16px;
    margin-top: 2rem;
    margin-bottom: 2rem;
    color: var(--white);
}

.post-header,
.page-header {
    margin-bottom: 2rem;
}

.post-header h1,
.page-header h1,
.gallery-overlay h2 {
    font-family: 'Bungee Shade', cursive;
    background: linear-gradient(90deg, var(--yellow), var(--pink), var(--yellow));
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 3s ease infinite;
}

.post-header h1,
.page-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.post-header time {
    color: var(--pink);
}

.post-image img,
.page-image img {
    width: 100%;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.post-content,
.page-content {
    font-size: 1.1rem;
    color: var(--white);
}

.post-content p,
.page-content p {
    margin-bottom: 1.5rem;
}

.post-content h2,
.page-content h2 {
    color: var(--yellow);
    margin: 2rem 0 1rem;
}

.post-content a,
.page-content a {
    color: var(--yellow);
    transition: color 0.2s ease, text-shadow 0.2s ease;
}

.post-content a:hover,
.page-content a:hover {
    color: var(--pink);
    text-shadow: 0 0 8px var(--pink), 0 0 16px rgba(233, 30, 140, 0.5);
}

/* Ghost content images - fit within container */
.post-content img,
.page-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

.post-content figure,
.page-content figure {
    margin: 1.5rem 0;
}

.kg-image-card,
.kg-gallery-card {
    max-width: 100%;
}

/* Ghost content width classes - disabled for glass container */
.kg-width-wide,
.kg-width-full {
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
}

/* Footer */
.site-footer {
    text-align: center;
    padding: 2rem;
    border-top: none;
    background: transparent;
    color: var(--gray);
}

.site-footer a {
    color: var(--pink);
    transition: text-shadow 0.2s ease;
}

.site-footer a:hover {
    text-shadow: 0 0 8px var(--pink), 0 0 16px rgba(233, 30, 140, 0.5);
}

/* Home page gallery - no max-width */
.home-template main {
    max-width: none;
    padding: 0;
}

/* Ghost Gallery Card */
.kg-gallery-container {
    display: flex;
    flex-direction: column;
    max-width: 100%;
}

.kg-gallery-row {
    display: flex;
    flex-direction: row;
    justify-content: center;
}

.kg-gallery-row:not(:first-of-type) {
    margin-top: 0.75em;
}

.kg-gallery-image img {
    display: block;
    margin: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.kg-gallery-image:not(:first-of-type) {
    margin-left: 0.75em;
}

/* Ghost Bookmark Card */
.kg-bookmark-card {
    width: 100%;
    margin: 1.5rem 0;
}

.kg-bookmark-container {
    display: flex;
    text-decoration: none;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    overflow: hidden;
    color: var(--white);
}

.kg-bookmark-container:hover {
    border-color: var(--pink);
}

.kg-bookmark-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 1.25rem;
}

.kg-bookmark-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--white);
}

.kg-bookmark-description {
    display: -webkit-box;
    overflow-y: hidden;
    margin-top: 0.5rem;
    max-height: 3rem;
    color: var(--gray);
    font-size: 0.875rem;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

.kg-bookmark-metadata {
    display: flex;
    align-items: center;
    margin-top: 1rem;
    font-size: 0.875rem;
    color: var(--gray);
}

.kg-bookmark-icon {
    width: 1.25rem;
    height: 1.25rem;
    margin-right: 0.5rem;
}

.kg-bookmark-author {
    color: var(--gray);
}

.kg-bookmark-author::after {
    content: "•";
    margin: 0 0.5rem;
}

.kg-bookmark-publisher {
    color: var(--gray);
}

.kg-bookmark-thumbnail {
    position: relative;
    flex-shrink: 0;
    width: 200px;
}

.kg-bookmark-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Tag pages */
.tag-template main {
    max-width: none;
    padding: 0;
}

.tag-header {
    padding: 4rem 2rem 2rem;
    text-align: center;
    background: var(--dark);
}

.tag-header h1 {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.tag-description {
    color: var(--gray);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Large gallery variant for tag pages */
.gallery-large {
    grid-template-columns: repeat(auto-fill, minmax(500px, 1fr));
}

.gallery-large .gallery-item {
    aspect-ratio: 16/9;
}

.gallery-large .gallery-overlay h2 {
    font-size: 2rem;
}

/* Responsive */
@media (max-width: 768px) {
    .site-header {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: space-between;
    }

    .nav-toggle {
        display: block;
    }

    .site-nav {
        display: none;
        width: 100%;
        padding: 1rem 0;
    }

    .site-nav.is-open {
        display: block;
    }

    .site-nav ul {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }

    .post,
    .page {
        padding: 1.5rem;
        margin: 1rem;
    }

    .post-header h1,
    .page-header h1 {
        font-size: 1.8rem;
    }

    .tag-header h1 {
        font-size: 2rem;
    }

    .gallery-large {
        grid-template-columns: 1fr;
    }
}
