
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'WindowsCMD', sans-serif;
}

body {
    --color: rgba(0, 255, 255, 0.15);
    background-color: #0d0d0d;
    background-image: linear-gradient(0deg, transparent 24%, var(--color) 25%, var(--color) 26%, transparent 27%, transparent 74%, var(--color) 75%, var(--color) 76%, transparent 77%, transparent),
        linear-gradient(90deg, transparent 24%, var(--color) 25%, var(--color) 26%, transparent 27%, transparent 74%, var(--color) 75%, var(--color) 76%, transparent 77%, transparent);
    background-size: 55px 55px;
    color: white;
    width: 100%;
    min-height: 100vh;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 10%;
    background: #131313;
}

.logo {
    color: white;
    font-size: 24px;
    font-weight: 600;
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin: 0 15px;
}

nav ul li a {
    text-decoration: none;
    color: white;
    font-weight: 400;
    transition: color 0.3s ease-in-out;
}

nav ul li a:hover, .active {
    color: cyan;
}

/* Main Container for Two-Column Layout */
.main-container {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    min-height: 100vh;
    gap: 1.5rem;
    padding: 2rem 1.5%;
    align-items: flex-start;
    max-width: 100vw;
    overflow-x: hidden;
}

/* Left Sidebar - Profile Card (22%) */
.profile-sidebar {
    flex: 0 0 22%;
    width: 22%;
    max-width: 22%;
    min-width: 0;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 2rem;
    position: sticky;
    top: 2rem;
    height: fit-content;
    z-index: 1;
}

/* Right Main Area - Projects (78%) */
.projects-main {
    flex: 1 1 76.5%;
    width: 76.5%;
    max-width: 76.5%;
    min-width: 0;
    overflow-y: visible;
    z-index: 0;
}

/* Profile Card Styles */
.profile-card {
    width: 100%;
    max-width: 100%;
    min-height: 38em;
    background: #171717;
    transition: 1s ease-in-out;
    clip-path: polygon(
        30px 0%,
        100% 0,
        100% calc(100% - 30px),
        calc(100% - 30px) 100%,
        0 100%,
        0% 30px
    );
    border-top-right-radius: 20px;
    border-bottom-left-radius: 20px;
    display: flex;
    flex-direction: column;
    padding: 2em 1.2em;
    box-shadow: 0 0 20px rgba(0, 255, 255, 0.2);
}

.profile-card:hover {
    box-shadow: 0 0 40px rgba(0, 255, 255, 0.4);
    transform: translateY(-5px);
}

.profile-card .card-name {
    font-weight: bold;
    color: white;
    text-align: center;
    display: block;
    font-size: 1.6em;
    margin-bottom: 0.4em;
}

.profile-card .card-title {
    font-weight: 600;
    color: cyan;
    text-align: center;
    display: block;
    font-size: 1.2em;
    margin-bottom: 1em;
}

.profile-card .card-info {
    font-weight: 400;
    color: #bfbfbf;
    display: block;
    text-align: center;
    font-size: 0.95em;
    margin: 1em 0;
    line-height: 1.6;
    flex-grow: 1;
}

.profile-card .card-img {
    width: 10em;
    height: 10em;
    background: white;
    border-radius: 15px;
    margin: 1em auto;
    overflow: hidden;
    border: 3px solid cyan;
    box-shadow: 0 0 20px rgba(0, 255, 255, 0.3);
}

.profile-card .card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-card .card-share {
    margin-top: 1em;
    display: flex;
    justify-content: center;
    gap: 1.5em;
}

.profile-card .card-share a {
    color: white;
    font-size: 1.6em;
    transition: 0.4s ease-in-out;
}

.profile-card .card-share a:hover {
    color: cyan;
    transform: scale(1.2);
}

.profile-card .card-button {
    padding: 0.8em 1.7em;
    display: block;
    margin: 1.2em auto 0;
    border-radius: 25px;
    border: none;
    font-weight: bold;
    background: cyan;
    color: #0d0d0d;
    transition: 0.4s ease-in-out;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    font-family: inherit;
    font-size: 1em;
}

.profile-card .card-button:hover {
    background: white;
    color: #0d0d0d;
    box-shadow: 0 0 20px rgba(0, 255, 255, 0.5);
    transform: scale(1.05);
}

/* Project Grid (used by portfolio.html) */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.2rem;
    padding: 0;
    width: 100%;
}

/* Projects Feed (used by index.html) */
.projects-feed {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 0.25rem 0;
}

.feed-card {
    display: flex;
    flex-direction: row;
    background: #171717;
    border-radius: 10px;
    overflow: hidden;
    border-left: 3px solid cyan;
    box-shadow: 0 0 12px rgba(0, 255, 255, 0.08);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
    min-height: 160px;
}

.feed-card:hover {
    box-shadow: 0 0 28px rgba(0, 255, 255, 0.22);
    transform: translateX(5px);
}

.feed-card-image {
    flex: 0 0 190px;
    width: 190px;
    background: #1a1a1a;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.feed-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feed-card-icon {
    background: linear-gradient(135deg, #1a1a1a, #222);
}

.feed-card-icon i {
    font-size: 3.2rem;
    color: rgba(0, 255, 255, 0.75);
}

.feed-card-body {
    flex: 1;
    padding: 1.1rem 1.4rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    min-width: 0;
}

.feed-card-title {
    font-size: 1.1rem;
    color: cyan;
    font-weight: 700;
    margin: 0;
}

.feed-card-description {
    font-size: 0.85rem;
    color: #bfbfbf;
    line-height: 1.5;
    margin: 0;
    flex-grow: 1;
}

.feed-card-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.feed-card-links {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.25rem;
}

/* Project Widget - New Card Style */
.project-widget {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    background-color: #1a1a1a;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    perspective: 1000px;
    box-shadow: 0 0 0 5px rgba(0, 255, 255, 0.3);
    transition: all 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    opacity: 1;
}

.project-widget:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 16px rgba(0, 255, 255, 0.4), 0 0 30px rgba(0, 255, 255, 0.2);
}

.project-widget.hidden {
    opacity: 0;
    transform: scale(0.8);
    pointer-events: none;
}

.project-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background: linear-gradient(45deg, #1a1a1a, #2a2a2a);
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.project-image i {
    font-size: 4rem;
    color: rgba(0, 255, 255, 0.8);
    z-index: 2;
    transition: all 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.project-widget:hover .project-image i {
    scale: 0;
}

.project-widget:hover .project-image img {
    scale: 0;
}

.project-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 20px;
    box-sizing: border-box;
    background: linear-gradient(135deg, #0d0d0d 0%, #1a1a1a 100%);
    transform: rotateX(-90deg);
    transform-origin: bottom;
    transition: all 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.project-widget:hover .project-content {
    transform: rotateX(0deg);
}

.project-title {
    margin: 0 0 10px 0;
    font-size: 1.2rem;
    color: cyan;
    font-weight: 700;
}

.project-description {
    margin: 10px 0;
    font-size: 0.85rem;
    color: #bfbfbf;
    line-height: 1.4;
    flex-grow: 1;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin: 10px 0;
}

.tech-tag {
    background: rgba(0, 255, 255, 0.15);
    padding: 0.25rem 0.6rem;
    border-radius: 12px;
    font-size: 0.7rem;
    color: cyan;
    border: 1px solid rgba(0, 255, 255, 0.3);
}

.project-links {
    display: flex;
    gap: 0.5rem;
    margin-top: auto;
}

.project-link {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 8px 16px;
    background: rgba(0, 255, 255, 0.1);
    color: cyan;
    text-decoration: none;
    border-radius: 8px;
    border: 1px solid rgba(0, 255, 255, 0.3);
    transition: all 0.3s ease;
    font-size: 0.85rem;
}

.project-link:hover {
    background: rgba(0, 255, 255, 0.2);
    border-color: cyan;
    box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
}

.project-link i {
    font-size: 0.9rem;
}

/* ── Tablet (≤ 1100px) ──────────────────────────────────── */
@media (max-width: 1100px) {
    .profile-sidebar {
        flex: 0 0 28%;
        width: 28%;
        max-width: 28%;
    }
    .projects-main {
        flex: 1 1 70%;
        width: 70%;
        max-width: 70%;
    }
    .feed-card-image {
        flex: 0 0 160px;
        width: 160px;
    }
}

/* ── Mobile (≤ 768px) ───────────────────────────────────── */
@media (max-width: 768px) {
    header {
        padding: 1rem 3%;
        flex-direction: column;
        gap: 1rem;
    }

    nav ul { gap: 1rem; }

    body {
        background-size: 35px 35px;
    }

    .main-container {
        flex-direction: column;
        padding: 1rem 4%;
        gap: 1.5rem;
    }

    .profile-sidebar {
        flex: none;
        width: 100%;
        max-width: 100%;
        position: static;
        padding-top: 0;
    }

    .profile-card {
        width: 100%;
        max-width: 100%;
        min-height: unset;
        padding: 1.2em 1em;
    }

    .profile-card .card-name { font-size: 1.4em; }
    .profile-card .card-title { font-size: 1.05em; }
    .profile-card .card-info { font-size: 0.85em; }
    .profile-card .card-img { width: 8em; height: 8em; }
    .profile-card .card-share a { font-size: 1.4em; }

    .projects-main {
        width: 100%;
        max-width: 100%;
    }

    /* Portfolio grid (portfolio.html) */
    .projects-grid { grid-template-columns: 1fr; gap: 1.5rem; }
    .project-widget { aspect-ratio: 4/3; }
    .project-title { font-size: 1rem; }
    .project-description { font-size: 0.75rem; }

    /* Feed cards — stack vertically, top border instead of left */
    .feed-card {
        flex-direction: column;
        min-height: unset;
        border-left: none;
        border-top: 3px solid cyan;
    }
    .feed-card-image {
        flex: none;
        width: 100%;
        height: 160px;
    }
    .feed-card-body { padding: 0.9rem 1rem; }
    .feed-card-title { font-size: 1rem; }
    .feed-card-description { font-size: 0.8rem; }

    /* Touch-friendly tap targets (minimum 44px) */
    .project-link {
        min-height: 44px;
        font-size: 0.85rem;
        padding: 10px 14px;
    }
    .card-button {
        min-height: 44px;
        font-size: 0.95em;
    }
    .profile-card .card-share a {
        min-width: 44px;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .tech-tag { font-size: 0.68rem; padding: 0.22rem 0.55rem; }
}

/* ── Small phones (≤ 480px) — compact horizontal profile ── */
@media (max-width: 480px) {
    .main-container { padding: 0.75rem 3%; }

    .profile-card {
        display: grid;
        grid-template-columns: 74px 1fr;
        grid-template-rows: auto auto 1fr auto auto;
        grid-template-areas:
            "img  name"
            "img  title"
            "info info"
            "share share"
            "btn  btn";
        gap: 0.3em 0.8em;
        padding: 1em;
        min-height: unset;
        clip-path: polygon(
            20px 0%,
            100% 0,
            100% calc(100% - 20px),
            calc(100% - 20px) 100%,
            0 100%,
            0% 20px
        );
    }

    .profile-card .card-img {
        grid-area: img;
        width: 74px;
        height: 74px;
        margin: 0;
        align-self: start;
    }
    .profile-card .card-name {
        grid-area: name;
        text-align: left;
        font-size: 1.15em;
        margin-bottom: 0;
        align-self: end;
    }
    .profile-card .card-title {
        grid-area: title;
        text-align: left;
        font-size: 0.9em;
        margin-bottom: 0;
        align-self: start;
    }
    .profile-card .card-info {
        grid-area: info;
        text-align: left;
        font-size: 0.78em;
        margin: 0.5em 0 0.25em;
    }
    .profile-card .card-share {
        grid-area: share;
        justify-content: flex-start;
        margin-top: 0.4em;
    }
    .profile-card .card-button {
        grid-area: btn;
        margin: 0.5em 0 0;
    }

    .feed-card-image { height: 130px; }
    .projects-feed { gap: 0.75rem; }
}

/* ── Touch devices — disable misleading hover effects ───── */
@media (hover: none) and (pointer: coarse) {
    .profile-card:hover {
        transform: none;
        box-shadow: 0 0 20px rgba(0, 255, 255, 0.2);
    }
    .feed-card:hover {
        transform: none;
        box-shadow: 0 0 12px rgba(0, 255, 255, 0.08);
    }
    .project-widget:hover {
        transform: none;
        box-shadow: 0 0 0 5px rgba(0, 255, 255, 0.3);
    }
    .profile-card .card-share a:hover { transform: none; }
    .profile-card .card-button:hover { transform: none; }
    .footer-social-icons a:hover { transform: none; }
    .project-link:hover { box-shadow: none; }
}

/* Project Categories Specific Colors - Consistent dark theme */
.project-widget[data-category="web"] .project-image,
.project-widget[data-category="mobile"] .project-image,
.project-widget[data-category="desktop"] .project-image,
.project-widget[data-category="game"] .project-image,
.project-widget[data-category="console"] .project-image {
    background: linear-gradient(45deg, #1a1a1a, #2a2a2a);
}

/* Footer Styles */
footer {
    background: #131313;
    color: white;
    margin-top: 10px;
    padding: 40px 10%;
    border-top: 1px solid rgba(0, 255, 255, 0.2);
}

.footer-content {
    display: flex;
    justify-content: space-around;
    align-items: flex-start;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.footer-section {
    text-align: center;
    margin: 20px;
}

.footer-section h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 15px;
    color: cyan;
}

.footer-email {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.footer-email i {
    color: cyan;
    font-size: 20px;
    margin-right: 10px;
}

.footer-email a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-email a:hover {
    color: cyan;
}

.footer-social-icons {
    display: flex;
    justify-content: center;
}

.footer-social-icons a {
    text-decoration: none;
    color: white !important;
    font-size: 30px !important;
    transition: all 0.3s ease;
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 45px !important;
    height: 45px !important;
    border-radius: 50% !important;
    background: rgba(255, 255, 255, 0.1);
    margin: 0 10px;  
}

.footer-social-icons a:hover {
    color: cyan;
    background: rgba(0, 255, 255, 0.2);
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 255, 255, 0.3);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #bfbfbf;
    font-size: 14px;
    text-decoration: none;
    border-bottom: none; 
}

/* Responsive Footer */
@media (max-width: 768px) {
    footer {
        padding: 30px 5%;
    }

    .footer-content {
        flex-direction: column;
        align-items: center;
    }

    .footer-section {
        margin: 15px 0;
    }

    .footer-email {
        flex-direction: column;
        margin-bottom: 5px;
    }
    
    .footer-email i {
        margin-right: 0;
        margin-bottom: 5px;
    }
}