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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
    background: #f5f5f5;
    color: #000;
    overflow-x: hidden;
    height: 100vh;
    position: relative;
}

/* Creative dotted background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(circle, #000 1px, transparent 1px);
    background-size: 20px 20px;
    opacity: 0.1;
    z-index: 0;
    pointer-events: none;
}

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
    overflow-y: auto;
}

.modal-overlay.hidden {
    display: none;
}

.modal {
    background: #fff;
    border: 4px solid #000;
    box-shadow: 12px 12px 0 #000;
    padding: 60px 50px;
    max-width: 500px;
    width: 100%;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    margin: auto;
}

.modal h1 {
    font-size: 48px;
    font-weight: 900;
    margin-bottom: 8px;
    line-height: 1;
}

.modal h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 24px;
    color: #666;
}

.modal p {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 32px;
    color: #333;
}

.modal-btn {
    background: #000;
    color: #fff;
    border: 4px solid #000;
    padding: 16px 32px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 6px 6px 0 #FFD700;
    transition: none;
    text-decoration: none;
    display: inline-block;
}

.modal-btn:active {
    transform: translate(3px, 3px);
    box-shadow: 3px 3px 0 #FFD700;
}

/* Contact Modal */
.contact-modal {
    max-width: 600px;
    transition: max-width 0.3s ease;
}

.contact-modal.with-calendar {
    max-width: 900px;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    font-size: 36px;
    font-weight: 700;
    cursor: pointer;
    color: #000;
    line-height: 1;
    padding: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    opacity: 0.7;
}

.contact-form {
    margin-top: 30px;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    font-weight: 700;
    margin-bottom: 8px;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group select,
.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 3px solid #000;
    background: #fff;
    font-size: 16px;
    font-family: inherit;
    font-weight: 500;
    box-shadow: 4px 4px 0 #000;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.form-group select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L6 6L11 1' stroke='%23000' stroke-width='2' stroke-linecap='square'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
    cursor: pointer;
}

.form-group select:focus,
.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    transform: translate(-2px, -2px);
    box-shadow: 6px 6px 0 #000;
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-actions {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

#formActions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.form-actions .modal-btn {
    flex-shrink: 0;
    margin: 0;
}

.contact-email {
    margin: 0;
    padding: 0;
    font-size: 14px;
    color: #666;
    line-height: 1;
    height: fit-content;
}

.contact-email a {
    color: #000;
    font-weight: 700;
    text-decoration: none;
    border-bottom: 2px solid #000;
}

.contact-email a:hover {
    border-bottom-color: #FFD700;
}

.cal-widget-container {
    margin-top: 20px;
    margin-bottom: 20px;
}

.cal-widget-container > div {
    overflow: visible !important;
    height: auto !important;
    min-height: 500px;
}

/* Cal.com widget styling overrides */
.cal-widget-container iframe {
    border: none !important;
    box-shadow: none !important;
}

/* Main Container */
.container {
    margin: 0 auto;
    padding: 40px;
    height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
    overflow: hidden;
    justify-content: center;
}

/* Header */
header {
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transform: translateY(40px);
    opacity: 0;
    transition: transform 0.6s cubic-bezier(0.65, 0, 0.35, 1), opacity 0.6s ease;
}

header.loaded {
    transform: translateY(0);
    opacity: 1;
    transition-delay: 0.1s;
}

.logo {
    font-size: 32px;
    font-weight: 900;
    color: #000;
    display: inline-block;
}

.back-button {
    font-size: 24px;
    font-weight: 700;
    color: #000;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: transform 0.2s ease;
}

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

.header-nav {
    display: flex;
    gap: 32px;
    align-items: center;
}

.nav-link {
    font-size: 18px;
    font-weight: 700;
    color: #000;
    text-decoration: none;
    transition: transform 0.2s ease;
    position: relative;
}

.nav-link:hover {
    transform: translateY(-2px);
}

.nav-link.active {
    border-bottom: 3px solid #000;
    padding-bottom: 2px;
}

.nav-link-button {
    background: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    padding: 0;
}

/* Main Grid - 10 columns x 5 rows */
.main-grid {
    display: grid;
    grid-template-columns: repeat(10, minmax(60px, 1fr));
    grid-template-rows: repeat(5, 1fr);
    gap: 30px;
    flex: 1;
    min-height: 0;
    width: 100%;
    max-width: 1540px;
    margin: 0 auto;
}

/* Platform User Manager: 4x3 - starts at column 1, row 1 */
.main-grid > .project-1 {
    grid-column: 1 / 5;
    grid-row: 1 / 4;
    opacity: 0;
    animation: slideInUp 0.6s cubic-bezier(0.65, 0, 0.35, 1) 0.1s forwards;
}

/* B2B Meal Planner: 4x3 - starts at column 5, row 1 */
.main-grid > .project-2 {
    grid-column: 5 / 9;
    grid-row: 1 / 4;
    opacity: 0;
    animation: slideInUp 0.6s cubic-bezier(0.65, 0, 0.35, 1) 0.2s forwards;
}

/* Sidebar container: 2x5 - starts at column 9, row 1 */
.main-grid > .sidebar-container {
    grid-column: 9 / 11;
    grid-row: 1 / 6;
    display: flex;
    flex-direction: column;
    gap: 30px;
    opacity: 0;
    animation: slideInUp 0.6s cubic-bezier(0.65, 0, 0.35, 1) 0.3s forwards;
}

.sidebar-container > .cv-box {
    flex: 1;
    opacity: 1;
    animation: none;
}

.sidebar-container > .linkedin-btn {
    flex: 0 0 auto;
    height: 80px;
    opacity: 1;
    animation: none;
    background: #0A66C2;
    color: #fff;
}

.sidebar-container > .linkedin-btn:hover {
    background: #004182;
}

.sidebar-container > .email-btn {
    flex: 0 0 auto;
    height: 80px;
    opacity: 1;
    animation: none;
}

.sidebar-container > .contact-btn {
    flex: 0 0 auto;
    height: 80px;
    opacity: 1;
    animation: none;
}

/* Artificial Creatures: 2.67x2 - starts at column 1, row 4 */
.main-grid > .project-3 {
    grid-column: 1 / 4;
    grid-row: 4 / 6;
    opacity: 0;
    animation: slideInUp 0.6s cubic-bezier(0.65, 0, 0.35, 1) 0.4s forwards;
}

/* flip-the-binck: 2.67x2 - starts at column 4, row 4 */
.main-grid > .project-4 {
    grid-column: 4 / 6;
    grid-row: 4 / 6;
    opacity: 0;
    animation: slideInUp 0.6s cubic-bezier(0.65, 0, 0.35, 1) 0.45s forwards;
}

/* Another notes app: 2x2 - starts at column 6, row 4 */
.main-grid > .project-5 {
    grid-column: 6 / 9;
    grid-row: 4 / 6;
    opacity: 0;
    animation: slideInUp 0.6s cubic-bezier(0.65, 0, 0.35, 1) 0.5s forwards;
}

.project-card {
    background: #fff;
    border: 4px solid #000;
    box-shadow: 8px 8px 0 #000;
    display: flex;
    flex-direction: column;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    padding: 0;
    text-decoration: none;
    color: #000;
}

.project-card:hover {
    transform: translate(-4px, -4px);
    box-shadow: 12px 12px 0 #000;
}

.project-card.large {
    font-size: 32px;
}

.project-card .project-image {
    width: 100%;
    flex: 1;
    object-fit: cover;
    display: block;
    min-height: 0;
}

.project-card .project-title {
    font-size: inherit;
    padding: 20px;
    background: inherit;
    border-top: 4px solid #000;
    flex-shrink: 0;
    color: #000;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.project-card .project-title::after {
    content: '→';
    font-size: inherit;
    font-weight: 700;
    opacity: 0;
    transform: translateX(-10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.project-card:hover .project-title::after {
    opacity: 1;
    transform: translateX(0);
}

.project-card .project-description {
    font-size: 14px;
    font-weight: 400;
    color: #666;
    line-height: 1.4;
}

.project-card.project-1 {
    background: #FFD700;
}

.project-card.project-2 {
    background: #FF6B6B;
}

.project-card.project-3 {
    background: #4ECDC4;
}

.project-card.project-4 {
    background: #95E1D3;
}

.project-card.project-5 {
    background: #F38181;
}

.project-card.project-6 {
    background: #AA96DA;
}

/* Icon Buttons */
.icon-btn {
    background: #fff;
    border: 4px solid #000;
    box-shadow: 8px 8px 0 #000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    color: #000;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    padding: 0;
}

.icon-btn:hover {
    transform: translate(-4px, -4px);
    box-shadow: 12px 12px 0 #000;
}

.icon-btn:active {
    transform: translate(2px, 2px);
    box-shadow: 4px 4px 0 #000;
}

.icon-btn svg {
    width: 32px;
    height: 32px;
}

.cv-box {
    background: #fff;
    border: 4px solid #000;
    box-shadow: 8px 8px 0 #000;
    padding: 40px 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
    cursor: pointer;
    flex: 1;
    text-decoration: none;
    color: #000;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cv-box:hover {
    transform: translate(-4px, -4px);
    box-shadow: 12px 12px 0 #000;
}

.contact-btn {
    background: #000;
    color: #fff;
    border: 4px solid #000;
    box-shadow: 8px 8px 0 #FFD700;
    padding: 24px;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    display: block;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    width: 100%;
    font-family: inherit;
}

.contact-btn:hover {
    transform: translate(-4px, -4px);
    box-shadow: 12px 12px 0 #FFD700;
}

/* Creative Elements */
.creative-element {
    position: fixed;
    z-index: 2;
    pointer-events: none;
}

.circle-1 {
    width: 100px;
    height: 100px;
    border: 4px solid #FF6B6B;
    border-radius: 50%;
    top: 10%;
    right: 15%;
}

.circle-2 {
    width: 60px;
    height: 60px;
    background: #4ECDC4;
    border: 4px solid #000;
    border-radius: 50%;
    bottom: 15%;
    left: 10%;
}

.square-1 {
    width: 80px;
    height: 80px;
    background: #FFD700;
    border: 4px solid #000;
    top: 50%;
    left: 5%;
    transform: rotate(15deg);
}

.line-1 {
    width: 4px;
    height: 150px;
    background: #000;
    top: 20%;
    left: 30%;
    transform: rotate(25deg);
}

.zigzag {
    width: 100px;
    height: 100px;
    bottom: 20%;
    right: 10%;
}

.zigzag svg {
    width: 100%;
    height: 100%;
}

/* About Page */
.about-area {
    display: flex;
    flex-direction: column;
    gap: 30px;
    min-height: 0;
}

.about-card {
    background: #fff;
    border: 4px solid #000;
    box-shadow: 8px 8px 0 #000;
    padding: 60px;
    height: 100%;
}

.about-card h1 {
    font-size: 48px;
    font-weight: 900;
    margin-bottom: 8px;
    line-height: 1;
}

.about-card h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 40px;
    color: #666;
}

.about-section {
    margin-bottom: 32px;
}

.about-section h3 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.about-section p {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
}

/* Contact Page */
.contact-area {
    display: flex;
    flex-direction: column;
    gap: 30px;
    min-height: 0;
}

.contact-card {
    background: #fff;
    border: 4px solid #000;
    box-shadow: 8px 8px 0 #000;
    padding: 60px;
    height: 100%;
}

.contact-card h1 {
    font-size: 48px;
    font-weight: 900;
    margin-bottom: 8px;
    line-height: 1;
}

.contact-card .contact-form {
    margin-top: 30px;
}

/* Responsive */
@media (max-width: 1200px) {
    .main-grid {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
        gap: 20px;
    }

    .main-grid > * {
        grid-column: 1 !important;
        grid-row: auto !important;
        min-height: 200px;
    }

    .icon-btn {
        min-height: 80px;
    }

    .container {
        height: auto;
        min-height: 100vh;
        overflow-y: auto;
    }
}

@media (max-width: 768px) {
    .large-projects {
        grid-template-columns: 1fr;
    }

    .modal h1 {
        font-size: 36px;
    }

    .modal h2 {
        font-size: 20px;
    }

    .container {
        padding: 20px;
    }

    .creative-element {
        display: none;
    }

    header {
        flex-direction: column;
        gap: 20px;
        align-items: flex-start;
    }

    .header-nav {
        gap: 20px;
    }

    .nav-link {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .sidebar {
        flex-direction: column;
    }
}

/* Page Load Animations */
@keyframes slideInUp {
    from {
        transform: translateY(40px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}
