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

:root {
    --bg: #0a0a0a;
    --text: #faf8f5;
    --accent: #ff4e00;
    --muted: #999;
    --border: #2a2a2a;
}

#grid-bg {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    background: #0a0a0a;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: 'Space Mono', monospace;
    font-size: 16px;
    line-height: 1.7;
    overflow-x: hidden;
    position: relative;
}

/* Left side profile photo */
.profile-photo-left {
    position: fixed;
    left: 50px;
    top: 165px;
    width: 150px;
    height: 180px;
    border: 3px solid var(--text);
    background: #f0f0f0;
    z-index: 10;
    overflow: hidden;
}

.profile-photo-left img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.profile-photo-left .photo-placeholder {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: 'Space Mono', monospace;
    font-size: 12px;
    color: var(--muted);
    text-align: center;
    pointer-events: none;
}

.profile-photo-left img[src=""] + .photo-placeholder {
    display: block;
}

.profile-photo-left img:not([src=""]) + .photo-placeholder {
    display: none;
}


/* Animated background texture */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0,0,0,.02) 2px, rgba(0,0,0,.02) 4px);
    pointer-events: none;
    z-index: 0;
    animation: grain 8s steps(10) infinite;
}

@keyframes grain {
    0%, 100% { transform: translate(0, 0); }
    10% { transform: translate(-5%, -10%); }
    20% { transform: translate(-15%, 5%); }
    30% { transform: translate(7%, -25%); }
    40% { transform: translate(-5%, 25%); }
    50% { transform: translate(-15%, 10%); }
    60% { transform: translate(15%, 0%); }
    70% { transform: translate(0%, 15%); }
    80% { transform: translate(3%, 35%); }
    90% { transform: translate(-10%, 10%); }
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
    position: relative;
    z-index: 1;
}

/* Header */
header {
    margin-bottom: 60px;
    animation: slideDown 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.site-title {
    font-family: 'Space Mono', monospace;
    font-size: 14px;
    font-weight: 700;
    text-transform: lowercase;
    letter-spacing: 1px;
    margin-bottom: 20px;
    opacity: 0.6;
}

nav {
    display: flex;
    gap: 30px;
    border-bottom: 2px solid var(--text);
    padding-bottom: 10px;
}

nav a {
    color: var(--text);
    text-decoration: none;
    font-weight: 700;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
    transition: color 0.3s;
}

nav a:hover {
    color: var(--accent);
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

nav a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    margin: 40px 0 20px 0;
    animation: fadeIn 0.8s 0.2s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

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

.hero h1 {
    font-family: 'Fraunces', serif;
    font-size: clamp(48px, 8vw, 96px);
    font-weight: 900;
    line-height: 0.95;
    margin-bottom: 30px;
    font-style: italic;
}

.hero h1 .highlight {
    color: var(--accent);
    display: inline-block;
    animation: wobble 2s ease-in-out infinite;
}

@keyframes wobble {
    0%, 100% { transform: rotate(-2deg); }
    50% { transform: rotate(2deg); }
}

/* Content Sections */
section {
    margin-bottom: 100px;
    animation: fadeIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

section:nth-child(2) { animation-delay: 0.3s; }
section:nth-child(3) { animation-delay: 0.4s; }
section:nth-child(4) { animation-delay: 0.5s; }
section:nth-child(5) { animation-delay: 0.6s; }

h2 {
    font-family: 'Fraunces', serif;
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 30px;
    position: relative;
    display: inline-block;
}

.hero h2 {
    font-size: clamp(36px, 6vw, 64px);
    font-weight: 900;
    line-height: 0.95;
    margin-bottom: 0;
    font-style: italic;
}

h2::after {
    content: '↓';
    position: absolute;
    right: -40px;
    top: 0;
    color: var(--accent);
    font-size: 24px;
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(10px); }
}

.intro-text {
    font-size: 18px;
    line-height: 1.8;
    margin-bottom: 30px;
}

.intro-text strong {
    background: linear-gradient(120deg, var(--accent) 0%, var(--accent) 100%);
    background-repeat: no-repeat;
    background-size: 100% 30%;
    background-position: 0 85%;
    font-weight: 700;
}

.intro-text a {
    color: var(--text);
    text-decoration: none;
}

.intro-text a strong {
    background: linear-gradient(120deg, var(--accent) 0%, var(--accent) 100%);
    background-repeat: no-repeat;
    background-size: 100% 30%;
    background-position: 0 85%;
    font-weight: 700;
}

.intro-text em {
    font-style: italic;
    font-family: 'Fraunces', serif;
    font-size: 20px;
    font-weight: 300;
}

/* Currently Exploring Section */
.currently-exploring {
    margin: 40px 0;
}

.currently-exploring h3 {
    font-family: 'Space Mono', monospace;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 15px;
}

.currently-exploring ul {
    list-style: disc;
    margin-left: 20px;
    margin-bottom: 20px;
}

.currently-exploring ul li {
    font-size: 18px;
    line-height: 1.8;
    margin-bottom: 5px;
}

.currently-exploring p {
    font-size: 18px;
    line-height: 1.8;
}

.currently-exploring strong {
    background: linear-gradient(120deg, var(--accent) 0%, var(--accent) 100%);
    background-repeat: no-repeat;
    background-size: 100% 30%;
    background-position: 0 85%;
    font-weight: 700;
}

/* Work Grid */
.work-grid {
    display: grid;
    gap: 40px;
    margin-top: 40px;
}

.work-item {
    position: relative;
    border: 3px solid var(--text);
    padding: 30px;
    background: var(--bg);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.work-item:hover {
    transform: translateX(10px);
}

.work-item h3 {
    font-family: 'Fraunces', serif;
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 15px;
    transition: color 0.2s;
}

.work-item-link {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.work-item video,
.work-item img {
    position: relative;
    z-index: 2;
}

.work-item:has(.work-item-link) {
    cursor: pointer;
}

.work-item:has(.work-item-link):hover h3 {
    color: var(--accent);
}

.work-item p {
    font-size: 16px;
    line-height: 1.7;
}

/* Image Grid */
.image-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 40px 0;
}

.image-item {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4/3;
    border: 3px solid var(--text);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.image-item:hover {
    transform: scale(1.05) rotate(-2deg);
    z-index: 2;
}

.image-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(0.3) contrast(1.1);
    transition: filter 0.3s;
}

.image-item:hover img {
    filter: grayscale(0) contrast(1);
}

.image-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(26, 26, 26, 0.9);
    color: white;
    padding: 10px;
    font-size: 12px;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.image-item:hover .image-caption {
    transform: translateY(0);
}

/* Quest List */
.quest-list {
    list-style: none;
    margin: 30px 0;
}

.quest-list li {
    position: relative;
    padding-left: 40px;
    margin-bottom: 20px;
    font-size: 18px;
    transition: transform 0.2s;
}

.quest-list li:hover {
    transform: translateX(10px);
}

.quest-list li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: var(--accent);
    font-size: 24px;
    font-weight: 700;
}

/* Philosophy Block */
.philosophy {
    background: var(--text);
    color: var(--bg);
    padding: 40px;
    margin: 60px 0;
    border: 4px solid var(--accent);
    position: relative;
    transform: rotate(-1deg);
}

.philosophy::before {
    content: '';
    position: absolute;
    top: -8px;
    left: -8px;
    right: 8px;
    bottom: 8px;
    border: 4px solid var(--text);
    z-index: -1;
}

.philosophy p {
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 15px;
}

.philosophy strong {
    color: var(--accent);
    font-weight: 700;
}

/* Contact Section */
.contact-links {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 30px;
}

.contact-links a {
    background: var(--text);
    color: var(--bg);
    padding: 15px 30px;
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 14px;
    letter-spacing: 1px;
    border: 3px solid var(--text);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
}

.contact-links a::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: -1;
}

.contact-links a:hover {
    color: var(--bg);
    border-color: var(--accent);
}

.contact-links a:hover::before {
    transform: scaleX(1);
}

/* Footer */
footer {
    margin-top: 100px;
    padding: 40px 0;
    border-top: 2px solid var(--border);
    text-align: center;
    font-size: 14px;
    opacity: 0.6;
}

/* Responsive */
@media (max-width: 768px) {
    .profile-photo-left {
        display: none;
    }

    .container {
        padding: 30px 15px;
    }

    nav {
        flex-direction: column;
        gap: 15px;
    }

    .hero {
        margin: 40px 0;
    }

    section {
        margin-bottom: 60px;
    }

    .philosophy {
        padding: 30px 20px;
    }

    h2::after {
        display: none;
    }
}

/* Cursor effect */
@media (hover: hover) {
    body {
        cursor: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20"><circle cx="10" cy="10" r="8" fill="none" stroke="%23ff4e00" stroke-width="2"/></svg>') 10 10, auto;
    }
}

/* Blog */
.blog-list {
    display: grid;
    gap: 40px;
    margin-top: 20px;
}

.blog-post {
    border-left: 4px solid var(--accent);
    padding: 20px 30px;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.blog-post:hover {
    transform: translateX(10px);
}

.blog-date {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--muted);
    display: block;
    margin-bottom: 10px;
}

.blog-post h3 {
    font-family: 'Fraunces', serif;
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 10px;
}

.blog-post h3 a {
    color: var(--text);
    text-decoration: none;
    transition: color 0.2s;
}

.blog-post h3 a:hover {
    color: var(--accent);
}

.blog-post p {
    font-size: 15px;
    color: var(--muted);
    line-height: 1.7;
}

/* Webring skull image */
body > a:last-of-type {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-400px);
    z-index: 100;
}

body > a:last-of-type img {
    transition: transform 0.3s ease;
}

body > a:last-of-type img:hover {
    transform: scale(1.1);
}