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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    overflow-x: hidden;
    cursor: none;
}

/* Liquid Background */
.liquid-bg {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.liquid-bg svg {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 50%;
}

.wave1 {
    animation: wave 15s ease-in-out infinite;
}

.wave2 {
    animation: wave 12s ease-in-out infinite reverse;
}

.wave3 {
    animation: wave 18s ease-in-out infinite;
}

@keyframes wave {
    0%, 100% {
        transform: translateY(0) scaleY(1);
    }
    50% {
        transform: translateY(-30px) scaleY(1.1);
    }
}

/* Container */
.container {
    position: relative;
    z-index: 1;
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

/* Hero Section */
.hero {
    position: relative;
    text-align: center;
    padding: 4rem 2rem;
    overflow: hidden;
}

/* Liquid Blobs */
.liquid-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.3;
    animation: float 20s ease-in-out infinite;
}

.blob1 {
    width: 400px;
    height: 400px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    top: -100px;
    left: -100px;
    animation-delay: 0s;
}

.blob2 {
    width: 300px;
    height: 300px;
    background: linear-gradient(45deg, #f093fb, #f5576c);
    top: 50px;
    right: -50px;
    animation-delay: 5s;
}

.blob3 {
    width: 350px;
    height: 350px;
    background: linear-gradient(45deg, #4facfe, #00f2fe);
    bottom: -100px;
    left: 50%;
    animation-delay: 10s;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    33% {
        transform: translate(100px, -50px) scale(1.1);
    }
    66% {
        transform: translate(-50px, 50px) scale(0.9);
    }
}

/* Glitch Text Effect */
.glitch {
    position: relative;
    font-size: 4rem;
    font-weight: 900;
    color: #fff;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
    animation: glitch-skew 5s infinite linear alternate-reverse;
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch::before {
    animation: glitch-anim 2s infinite linear alternate-reverse;
    color: #f0f;
    z-index: -1;
}

.glitch::after {
    animation: glitch-anim 3s infinite linear alternate-reverse;
    color: #0ff;
    z-index: -2;
}

@keyframes glitch-anim {
    0% {
        clip-path: polygon(0 0, 100% 0, 100% 5%, 0 5%);
        transform: translateX(2px);
    }
    20% {
        clip-path: polygon(0 15%, 100% 15%, 100% 25%, 0 25%);
        transform: translateX(-2px);
    }
    40% {
        clip-path: polygon(0 40%, 100% 40%, 100% 60%, 0 60%);
        transform: translateX(2px);
    }
    60% {
        clip-path: polygon(0 70%, 100% 70%, 100% 75%, 0 75%);
        transform: translateX(-2px);
    }
    80% {
        clip-path: polygon(0 85%, 100% 85%, 100% 95%, 0 95%);
        transform: translateX(2px);
    }
    100% {
        clip-path: polygon(0 95%, 100% 95%, 100% 100%, 0 100%);
        transform: translateX(-2px);
    }
}

@keyframes glitch-skew {
    0%, 100% {
        transform: skew(0deg);
    }
    50% {
        transform: skew(1deg);
    }
}

.subtitle {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.9);
    margin-top: 1rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

/* Projects Section - Mark Cuban Style Grid */
.projects {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    padding: 2rem 0;
}

.project-card {
    position: relative;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(20px);
    border-radius: 16px;
    padding: 2rem 1.5rem;
    border: 2px solid rgba(255, 255, 255, 0.2);
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    cursor: pointer;
    min-height: 200px;
    display: flex;
    flex-direction: column;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, transparent, rgba(255, 255, 255, 0.15));
    opacity: 0;
    transition: opacity 0.4s ease;
}

.project-card:hover::before {
    opacity: 1;
}

.project-card:hover {
    transform: translateY(-8px) scale(1.03);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.2);
}

.project-card-inner {
    position: relative;
    z-index: 1;
}

.project-card h2 {
    color: #fff;
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    font-weight: 700;
}

.project-card .short-description {
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.5;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.project-card .tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: auto;
}

.tag {
    background: rgba(255, 255, 255, 0.25);
    padding: 0.4rem 0.9rem;
    border-radius: 20px;
    font-size: 0.85rem;
    color: #fff;
    backdrop-filter: blur(10px);
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.modal.active {
    opacity: 1;
    pointer-events: all;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
}

.modal-content {
    position: relative;
    background: rgba(20, 20, 30, 0.95);
    backdrop-filter: blur(30px);
    border-radius: 24px;
    padding: 0;
    max-width: 90vw;
    width: 1200px;
    max-height: 90vh;
    height: 80vh;
    overflow: hidden;
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.6);
    border: 2px solid rgba(255, 255, 255, 0.1);
    transform: scale(0.9);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    width: 45px;
    height: 45px;
    border-radius: 50%;
    font-size: 1.8rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    transition: all 0.3s ease;
    z-index: 10;
    backdrop-filter: blur(10px);
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
    border-color: rgba(255, 255, 255, 0.4);
}

.modal-header {
    padding: 2rem 2.5rem;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2), rgba(118, 75, 162, 0.2));
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
}

.modal-info {
    flex: 1;
}

.modal-title {
    font-size: 2rem;
    color: #fff;
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.modal-description {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.modal-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.modal-tags .tag {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.modal-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.9rem 1.5rem;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    white-space: nowrap;
}

.modal-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(102, 126, 234, 0.6);
}

.modal-button svg {
    width: 18px;
    height: 18px;
}

.modal-iframe-container {
    flex: 1;
    position: relative;
    background: #fff;
    overflow: hidden;
}

.modal-iframe-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 40px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.05), transparent);
    pointer-events: none;
    z-index: 1;
}

#modalIframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

/* Liquid Cursor */
.cursor-liquid {
    position: fixed;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.2));
    pointer-events: none;
    z-index: 9999;
    transition: transform 0.2s ease, width 0.3s ease, height 0.3s ease;
    mix-blend-mode: difference;
    filter: blur(5px);
}

.cursor-liquid.expand {
    width: 60px;
    height: 60px;
    filter: blur(10px);
}

/* Responsive */
@media (max-width: 768px) {
    .glitch {
        font-size: 2.5rem;
    }

    .subtitle {
        font-size: 1.2rem;
    }

    .projects {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .modal-content {
        width: 95vw;
        height: 85vh;
        max-height: 85vh;
    }

    .modal-header {
        padding: 1.5rem;
        flex-direction: column;
        gap: 1rem;
    }

    .modal-title {
        font-size: 1.5rem;
    }

    .modal-description {
        font-size: 0.95rem;
    }

    .modal-button {
        width: 100%;
        justify-content: center;
        font-size: 0.9rem;
        padding: 0.8rem 1.2rem;
    }

    .modal-close {
        width: 40px;
        height: 40px;
        top: 1rem;
        right: 1rem;
    }

    body {
        cursor: auto;
    }

    .cursor-liquid {
        display: none;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .projects {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
}

/* Scrollbar Styles */
.modal-content::-webkit-scrollbar {
    width: 8px;
}

.modal-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 10px;
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #764ba2, #667eea);
}
