/* Minimal Three.js Portfolio */
:root {
    --primary: #2d1a1f;
    --secondary: #5a3e36;
    --accent: #a53860;
    --bg: #f5f0e6;
    --text: #2d1a1f;
    --text-light: rgba(45, 26, 31, 0.7);
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Space Grotesk', sans-serif;
    color: var(--text);
    background: var(--bg);
    overflow-x: hidden;
    line-height: 1.6;
}

.webgl-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.9;
}

.content-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-header {
    padding: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    width: 100%;
    z-index: 100;
    mix-blend-mode: difference;
    color: white;
}

.site-title {
    font-weight: 300;
    font-size: 1.5rem;
    letter-spacing: 0.1em;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: inherit;
    text-decoration: none;
    font-size: 0.9rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    position: relative;
    transition: var(--transition);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: currentColor;
    transition: var(--transition);
}

.nav-link:hover::after {
    width: 100%;
}

.hero {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 2rem;
    text-align: center;
}

.hero-content {
    max-width: 800px;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--text-light);
    font-size: 0.8rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    opacity: 0.7;
    transition: var(--transition);
}

.scroll-indicator:hover {
    opacity: 1;
}

.arrow {
    width: 1px;
    height: 40px;
    background: var(--text-light);
    margin-top: 1rem;
    position: relative;
}

.arrow::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 10px;
    height: 10px;
    border-right: 1px solid var(--text-light);
    border-bottom: 1px solid var(--text-light);
    transform: translate(-50%, 50%) rotate(45deg);
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translate(-50%, 0) rotate(45deg);
    }
    40% {
        transform: translate(-50%, -10px) rotate(45deg);
    }
    60% {
        transform: translate(-50%, -5px) rotate(45deg);
    }
}

/* Model Switcher */
.model-switcher {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 1rem;
    z-index: 100;
}

.model-switch {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    cursor: pointer;
    backdrop-filter: blur(10px);
    transition: var(--transition);
    font-family: inherit;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.model-switch:hover {
    background: rgba(255, 255, 255, 0.2);
}

.model-switch.active {
    background: white;
    color: var(--primary);
}

/* Texture Overlay */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.1'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: -1;
    mix-blend-mode: overlay;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .site-header {
        padding: 1.5rem;
    }
    
    .nav-links {
        gap: 1.5rem;
    }
    
    .site-title {
        font-size: 1.2rem;
    }
    
    .nav-link {
        font-size: 0.8rem;
    }
}

/* Print Styles */
@media print {
    .webgl-canvas,
    .scroll-indicator,
    .site-header {
        display: none;
    }
    
    body {
        background: white !important;
        color: black !important;
        padding: 1cm;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Utility Classes */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Theme Toggle */
.theme-toggle {
    position: fixed;
    top: 2rem;
    right: 2rem;
    z-index: 1000;
    cursor: pointer;
    transition: var(--transition);
}

.toggle-track {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50px;
    padding: 0.5rem 1rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border: 2px solid var(--primary-color);
    position: relative;
    transition: var(--transition);
}

.theme-toggle.hover .toggle-track {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.toggle-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--primary-color);
    position: absolute;
    left: 8px;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] .toggle-thumb {
    transform: translateX(calc(100% + 10px));
    background: var(--accent-dark);
}

.toggle-label {
    font-family: 'Righteous', cursive;
    font-size: 0.9rem;
    padding: 0 0.5rem;
    transition: var(--transition);
}

.toggle-label.light {
    color: var(--primary-color);
    margin-left: 30px;
}

.toggle-label.dark {
    color: var(--text-dark);
    opacity: 0;
    position: absolute;
    right: 1rem;
}

[data-theme="dark"] .toggle-label.light {
    opacity: 0;
}

[data-theme="dark"] .toggle-label.dark {
    opacity: 1;
}

/* Container with Memphis Style */
.container {
    max-width: 1000px;
    margin: 2rem auto;
    background: 
        linear-gradient(rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.8)),
        url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiPjxkZWZzPjxwYXR0ZXJuIGlkPSJwYXR0ZXJuIiB3aWR0aD0iMTAwIiBoZWlnaHQ9IjEwMCIgcGF0dGVyblVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgcGF0dGVyblRyYW5zZm9ybT0icm90YXRlKDQ1KSI+PHJlY3Qgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgZmlsbD0icmdiYSgyNTUsMjU1LDI1NSwwLjEpIi8+PC9wYXR0ZXJuPjwvZGVmcz48cmVjdCB3aWR0aD0iMTAwJSIgaGVpZ2h0PSIxMDAlIiBmaWxsPSJ1cmwoI3BhdHRlcm4pIi8+PC9zdmc+');
    backdrop-filter: var(--blur);
    border-radius: var(--border-radius);
    padding: 3rem;
    box-shadow: 
        0 10px 30px rgba(93, 64, 55, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(93, 64, 55, 0.1);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

/* Subtle Leaf Decoration */
.container::before {
    content: '🍃';
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 2rem;
    opacity: 0.3;
    transform: rotate(15deg);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(15deg); }
    50% { transform: translateY(-10px) rotate(20deg); }
}

.container:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 40px 0 rgba(31, 38, 135, 0.2);
}

/* Memphis Typography */
.memphis-header {
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
    padding: 2rem 0;
}

.memphis-title {
    font-family: 'Bungee Shade', cursive;
    font-size: 3.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
    text-shadow: 3px 3px 0 var(--highlight);
    letter-spacing: -1px;
    line-height: 1.1;
    position: relative;
    display: inline-block;
    transform: rotate(-2deg);
}

.highlight {
    color: var(--accent-color);
    position: relative;
    display: inline-block;
}

.highlight::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 0;
    width: 100%;
    height: 12px;
    background: var(--highlight);
    z-index: -1;
    opacity: 0.6;
    transform: rotate(-1deg);
}

h1::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--gradient-start), transparent);
    border-radius: 2px;
}

h2 {
    font-size: 2rem;
    color: var(--primary-color);
    margin: 2rem 0 1.5rem;
    position: relative;
    display: inline-block;
}

h2::after {
    content: '';
    position: absolute;
    width: 50%;
    height: 4px;
    bottom: -8px;
    left: 0;
    background: linear-gradient(90deg, var(--gradient-start), var(--accent-color));
    border-radius: 2px;
}

p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-color);
    margin-bottom: 1.5rem;
}

/* Header Styles */
header {
    text-align: center;
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

header p {
    font-size: 1.3rem;
    color: var(--accent-color);
    font-weight: 500;
    max-width: 700px;
    margin: 0 auto;
}

/* Content Section */
.content {
    margin-bottom: 4rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.tagline {
    font-family: 'Righteous', cursive;
    font-size: 1.6rem;
    color: var(--secondary-color);
    margin: 1.5rem 0;
    position: relative;
    display: inline-block;
    padding: 0.5rem 1.5rem;
    background: white;
    border: 2px dashed var(--accent-color);
    transform: rotate(1deg);
}

.memphis-underline {
    height: 8px;
    width: 200px;
    margin: 2rem auto;
    background: repeating-linear-gradient(
        45deg,
        var(--accent-color),
        var(--accent-color) 10px,
        var(--highlight) 10px,
        var(--highlight) 20px
    );
    border-radius: 4px;
}

/* Memphis Cards */
.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin: 4rem 0;
    position: relative;
    perspective: 1000px;
}

/* Decorative Elements */
.features::before {
    content: '❀';
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1.5rem;
    opacity: 0.5;
}

.feature-card {
    background: white;
    padding: 2.5rem 2rem;
    border-radius: var(--border-radius);
    box-shadow: 
        8px 8px 0 var(--primary-color),
        0 0 0 2px var(--primary-color);
    transition: var(--transition);
    border: 2px solid var(--primary-color);
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
    transform: translateZ(0);
}

.feature-card:hover {
    transform: translate(-4px, -4px);
    box-shadow: 
        12px 12px 0 var(--primary-color),
        0 0 0 2px var(--primary-color);
}

.memphis-pattern {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: var(--memphis-pattern);
    opacity: 0.1;
    pointer-events: none;
}

.memphis-icon {
    color: var(--accent-color);
    margin-right: 8px;
    font-size: 1.2em;
}

.memphis-sticker {
    position: absolute;
    top: -10px;
    right: -10px;
    background: var(--highlight);
    color: var(--primary-color);
    padding: 0.5rem 1rem;
    font-family: 'Righteous', cursive;
    font-size: 0.8rem;
    transform: rotate(15deg);
    box-shadow: 2px 2px 0 var(--primary-color);
    border: 2px solid var(--primary-color);
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--gradient-start), var(--accent-color));
    opacity: 0.8;
    transition: var(--transition);
}

.feature-card:hover::before {
    height: 6px;
    opacity: 1;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.feature-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.4rem;
}

.feature-card p {
    color: var(--text-color);
    font-size: 1rem;
    opacity: 0.9;
}

/* Memphis Buttons */
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-color);
    color: white;
    padding: 1rem 2.5rem;
    border-radius: 0;
    text-decoration: none;
    font-family: 'Righteous', cursive;
    font-weight: 600;
    margin-top: 1.5rem;
    transition: var(--transition);
    border: 2px solid var(--primary-color);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 4px 4px 0 var(--highlight);
}

.button:hover {
    transform: translate(-2px, -2px);
    box-shadow: 6px 6px 0 var(--highlight);
}

.button::after {
    content: '→';
    margin-left: 8px;
    transition: transform 0.3s ease;
    display: inline-block;
}

.button:hover::after {
    transform: translateX(4px);
}

/* Button Hover Effect */
.button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
}

.button:hover::before {
    left: 100%;
}

.button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(74, 111, 165, 0.4);
}

.cta-button {
    margin-top: 2rem;
    text-align: center;
}

/* Memphis Footer */
.memphis-footer {
    margin-top: 6rem;
    position: relative;
    padding: 4rem 0 2rem;
    background: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 10px,
        rgba(165, 56, 96, 0.1) 10px,
        rgba(165, 56, 96, 0.1) 20px
    );
    border-top: 4px dashed var(--accent-color);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    position: relative;
    padding: 2rem;
    background: white;
    margin: 0 2rem;
    border: 2px solid var(--primary-color);
    box-shadow: 8px 8px 0 var(--primary-color);
}

.footer-content::before {
    content: '~';
    font-size: 2rem;
    color: var(--secondary-color);
    opacity: 0.3;
    position: absolute;
    top: -10px;
}

.social-links {
    display: flex;
    gap: 1.5rem;
}

.social-links {
    display: flex;
    gap: 1.5rem;
    margin-top: 1rem;
}

.social-links a {
    color: var(--primary-color);
    font-weight: 500;
    font-size: 1.4rem;
    transition: var(--transition);
    text-decoration: none;
    background: white;
    width: 50px;
    height: 50px;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 4px 4px 0 var(--primary-color);
    border: 2px solid var(--primary-color);
    transform: rotate(-2deg);
    font-family: 'Fredoka One', cursive;
}

.social-links a:hover {
    transform: rotate(0deg) translateY(-4px);
    box-shadow: 6px 6px 0 var(--primary-color);
    background: var(--highlight);
    color: var(--primary-color);
}

.social-links a:hover {
    color: var(--primary-color);
    transform: translateY(-2px);
}

/* Footer */
footer {
    text-align: center;
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    color: var(--accent-color);
    font-weight: 500;
    font-size: 0.95rem;
}

/* Add a subtle animation to the content */
/* Memphis Animations */
@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(20px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

@keyframes leafFloat {
    0%, 100% { 
        transform: translate(0, 0) rotate(0deg);
    }
    25% { 
        transform: translate(5px, -5px) rotate(2deg);
    }
    50% { 
        transform: translate(0, -10px) rotate(-2deg);
    }
    75% { 
        transform: translate(-5px, -5px) rotate(2deg);
    }
}

/* Apply animations */
.content {
    animation: fadeIn 1s ease-out forwards;
}

.feature-card {
    animation: fadeIn 0.8s ease-out forwards;
    animation-delay: calc(var(--delay, 0) * 0.1s);
}

/* Add subtle hover effect to content */
.content p {
    position: relative;
    transition: var(--transition);
}

.content p:hover {
    transform: translateX(5px);
}

/* Dark Theme Styles */
[data-theme="dark"] {
    --primary-color: var(--primary-dark);
    --secondary-color: var(--secondary-dark);
    --accent-color: var(--accent-dark);
    --light-bg: var(--bg-dark);
    --card-bg: var(--card-dark);
    --text-color: var(--text-dark);
    --highlight: #ffcc00;
}

[data-theme="dark"] .container {
    background: rgba(45, 26, 46, 0.9);
    border: 2px solid var(--accent-dark);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .feature-card {
    background: rgba(45, 26, 46, 0.9);
    border-color: var(--accent-dark);
    box-shadow: 8px 8px 0 var(--accent-dark);
}

[data-theme="dark"] .feature-card:hover {
    box-shadow: 12px 12px 0 var(--accent-dark);
}

[data-theme="dark"] .button {
    background: var(--accent-dark);
    border-color: var(--accent-dark);
    color: var(--primary-dark);
}

/* Theme Transition */
.theme-transition * {
    transition: background-color 0.5s ease, color 0.3s ease, border-color 0.5s ease;
}

/* Responsive Design */

.content {
    animation: fadeIn 0.8s ease-out forwards;
}

/* Responsive Design */
@media (max-width: 768px) {
    body {
        padding: 0.5rem;
    }
    
    .container {
        padding: 1.5rem 1rem;
        margin: 0.5rem;
    }
    
    .memphis-title {
        font-size: 2.2rem;
        line-height: 1.2;
    }
    
    .tagline {
        font-size: 1.2rem;
        padding: 0.3rem 1rem;
    }
    
    .features {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
    
    .theme-toggle {
        top: 1rem;
        right: 1rem;
    }
    
    .toggle-track {
        padding: 0.3rem 0.8rem;
    }
    
    .toggle-label {
        font-size: 0.8rem;
    }
    
    .toggle-thumb {
        width: 20px;
        height: 20px;
    }
}
