:root {
    --bg-light: #fefcf8;
    --text-light: #1e293b;
    --border-light: #94a3b8;
    --accent-yellow: #fcd34d;
    --accent-yellow-dark: #fbbf24;
    --nav-line-light: rgba(148, 163, 184, 0.4);
    
    --bg-dark: #18201a;
    --text-dark: #f8fafc;
    --border-dark: #64748b;
    --nav-line-dark: rgba(148, 163, 184, 0.3);
}

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

html {
    scroll-behavior: smooth;
}

body {
    transition: background-color 0.3s, color 0.3s;
    overflow-x: hidden;
    position: relative;
}

/* Light Theme (Notebook Style) */
body[data-theme="light"] {
    background-color: var(--bg-light);
    color: var(--text-light);
    font-family: 'Caveat', cursive;
    font-size: 1.4rem;
    line-height: 1.6;
    background-image: repeating-linear-gradient(transparent, transparent 39px, #e2e8f0 39px, #e2e8f0 40px);
}

/* Dark Theme (Chalkboard Style) */
body[data-theme="dark"] {
    background-color: var(--bg-dark);
    color: var(--text-dark);
    font-family: 'Caveat', cursive;
    font-size: 1.4rem;
    line-height: 1.6;
    background-image: none;
}

h1, h2, h3, .logo, .btn, .social-btn, .skill-tag, .nav-links a {
    font-family: 'Permanent Marker', cursive;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    line-height: 1.3;
    margin-bottom: 20px;
    letter-spacing: 2px;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 30px;
    letter-spacing: 1.5px;
}

h3 {
    font-size: 1.8rem;
    margin-bottom: 15px;
}

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

.yellow-text {
    color: var(--accent-yellow-dark);
}

body[data-theme="dark"] .yellow-text {
    color: var(--accent-yellow);
}

.highlight-wavy {
    text-decoration: underline wavy var(--accent-yellow-dark);
    text-underline-offset: 6px;
}

body[data-theme="dark"] .highlight-wavy {
    text-decoration-color: var(--accent-yellow);
}

/* Navigation */
nav {
    padding: 20px 0;
}

.nav-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 2rem;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 30px;
}

.nav-links a {
    text-decoration: none;
    color: inherit;
    font-size: 1.2rem;
    position: relative;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--accent-yellow-dark);
}

body[data-theme="dark"] .nav-links a:hover, body[data-theme="dark"] .nav-links a.active {
    color: var(--accent-yellow);
}

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--accent-yellow-dark);
    border-radius: 2px;
}

body[data-theme="dark"] .nav-links a.active::after {
    background-color: var(--accent-yellow);
}

.theme-toggle {
    cursor: pointer;
    padding: 5px;
    border: 2px dashed currentColor;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s;
}

.theme-toggle:hover {
    transform: rotate(45deg);
}

/* Dividers */
.divider {
    width: 100%;
    height: 2px;
    background-image: linear-gradient(to right, currentColor 50%, transparent 50%);
    background-size: 15px 2px;
    background-repeat: repeat-x;
    opacity: 0.3;
    margin: 20px 0;
}

/* Section Quotes */
.section-quote {
    font-family: 'Caveat', cursive;
    font-size: 1.6rem;
    color: currentColor;
    opacity: 0.8;
    border-left: 4px solid #fcd34d;
    padding-left: 20px;
    margin: 0 0 30px 0;
    max-width: 600px;
    line-height: 1.4;
}
body[data-theme="dark"] .section-quote {
    border-left: 4px solid #38bdf8;
    opacity: 0.9;
}

/* Main Content */
main {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 80px 0;
}

/* Hero Section */
.hero-section {
    display: flex;
    align-items: center;
    gap: 50px;
    min-height: 70vh;
}

.hero-text {
    flex: 1.2;
}

.subtitle {
    font-size: 1.8rem;
    margin-bottom: 40px;
}

.hero-buttons {
    display: flex;
    gap: 20px;
}

.hero-image {
    flex: 0.8;
    display: flex;
    justify-content: center;
}

.polaroid {
    background: #fff;
    padding: 15px 15px 40px 15px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
    transform: rotate(3deg);
    position: relative;
    border: 1px solid #e2e8f0;
}

body[data-theme="dark"] .polaroid {
    background: #2a342e;
    border-color: #3f4e45;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

.polaroid img {
    width: 250px;
    height: 250px;
    object-fit: cover;
    filter: sepia(0.2) contrast(1.1);
}

.tape {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%) rotate(-2deg);
    width: 100px;
    height: 35px;
    background-color: rgba(252, 211, 77, 0.6);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    z-index: 2;
}

.caption {
    font-family: 'Caveat', cursive;
    font-size: 1.5rem;
    text-align: center;
    margin-top: 10px;
    color: #333;
}

body[data-theme="dark"] .caption {
    color: #eee;
}

/* Buttons */
.btn, .social-btn {
    display: inline-block;
    padding: 10px 25px;
    border: 2px dashed currentColor;
    background: transparent;
    color: inherit;
    text-decoration: none;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 4px;
}

.btn:hover, .social-btn:hover {
    background-color: currentColor;
    color: var(--bg-light);
}

body[data-theme="dark"] .btn:hover, body[data-theme="dark"] .social-btn:hover {
    color: var(--bg-dark);
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 50px;
}

.about-content p {
    margin-bottom: 20px;
    font-size: 1.6rem;
}

.stats-box {
    border: 2px dashed currentColor;
    padding: 30px;
    transform: rotate(-1deg);
    align-self: start;
}

.stats-box ul {
    list-style-type: none;
}

.stats-box li {
    margin-bottom: 10px;
    font-size: 1.4rem;
}

/* Skills Section */
.skills-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin-top: 40px;
}

.skill-tag {
    padding: 8px 20px;
    border: 2px dashed currentColor;
    font-size: 1.2rem;
    transform: rotate(calc(-2deg + 4deg * var(--random, 0.5)));
    transition: transform 0.2s;
}

.skill-tag:hover {
    transform: scale(1.1) rotate(0);
    background-color: var(--accent-yellow);
    color: #000;
    border-color: #000;
}

/* Projects Section */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 50px;
    margin-top: 40px;
}

.project-card {
    background-color: #fef08a;
    border: none;
    padding: 30px;
    box-shadow: 2px 4px 10px rgba(0,0,0,0.15);
    position: relative;
    color: #1e293b;
    display: flex;
    flex-direction: column;
    transform: rotate(calc(-2deg + 4deg * var(--random, 0.5)));
    transition: transform 0.3s, box-shadow 0.3s;
}

.project-card:hover {
    transform: scale(1.05) rotate(0);
    box-shadow: 5px 10px 20px rgba(0,0,0,0.25);
    z-index: 10;
}

.project-card::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 25px;
    background-color: rgba(255,255,255,0.5);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.project-card:nth-child(2n) { background-color: #bae6fd; }
.project-card:nth-child(3n) { background-color: #fbcfe8; }
.project-card:nth-child(4n) { background-color: #bbf7d0; }

body[data-theme="dark"] .project-card {
    background-color: #423c14; /* Dark Yellow */
    color: #e2e8f0;
    box-shadow: 2px 4px 10px rgba(0,0,0,0.5);
    border: none;
}

body[data-theme="dark"] .project-card::before {
    background-color: rgba(0,0,0,0.4);
}

body[data-theme="dark"] .project-card:nth-child(2n) { background-color: #17374a; }
body[data-theme="dark"] .project-card:nth-child(3n) { background-color: #4a1d34; }
body[data-theme="dark"] .project-card:nth-child(4n) { background-color: #193d25; }

.project-card:hover {
    transform: translateY(-5px);
}

.project-card p {
    flex-grow: 1;
    margin-bottom: 20px;
    font-size: 1.3rem;
}

.project-links {
    display: flex;
    gap: 10px;
}

.project-links .btn {
    padding: 5px 15px;
    font-size: 0.9rem;
}

/* Contact Section */
.social-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 30px;
}

/* Footer */
.footer-content {
    max-width: 1100px;
    margin: 0 auto;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    font-family: 'Permanent Marker', cursive;
    font-size: 1rem;
}

/* Responsive */
@media (max-width: 850px) {
    .hero-section {
        flex-direction: column-reverse;
        text-align: center;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-links {
        display: none;
    }
}

/* Doodle Pad */
#doodle-pad {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 9999;
    pointer-events: none;
}

/* Scribble Hover */
.scribble-hover {
    position: relative;
    display: inline-block;
}
.scribble-hover::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 10px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 10" preserveAspectRatio="none"><path d="M0,5 Q25,0 50,5 T100,5" stroke="%23fcd34d" stroke-width="4" stroke-linecap="round" fill="none"/></svg>') no-repeat;
    background-size: 100% 100%;
    transition: width 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}
body[data-theme="dark"] .scribble-hover::after {
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 10" preserveAspectRatio="none"><path d="M0,5 Q25,0 50,5 T100,5" stroke="%23fbbf24" stroke-width="4" stroke-linecap="round" fill="none"/></svg>') no-repeat;
}
.scribble-hover:hover::after, .scribble-hover.active::after {
    width: 100%;
}

/* End of File */
