/* Base Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-primary-500: #667eea;
    --color-primary-600: #764ba2;
    --gradient-primary: linear-gradient(135deg, var(--color-primary-500) 0%, var(--color-primary-600) 100%);
    --shadow-primary: 0 14px 26px rgba(102,126,234,0.28);
    --shadow-primary-soft: 0 10px 18px rgba(102,126,234,0.18);
}

html, body {
    height: 100%;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: #2c3e50;
    background: #f7f8fb;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 70px;
    background: rgba(255,255,255,0.96);
    border-bottom: 1px solid #eef0f3;
    z-index: 1000;
}

.nav-container {
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo h2 {
    font-size: 1.6rem;
    font-weight: 700;
}

.nav-menu {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: #2c3e50;
    text-decoration: none;
    font-weight: 500;
}

.nav-link:hover,
.nav-link.active {
    color: #4f8bff;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 24px;
    height: 3px;
    background: #2c3e50;
    margin: 3px 0;
}

/* Hero */
.hero {
    background: var(--gradient-primary);
    color: #fff;
    padding: 140px 0 80px; /* offset for fixed navbar */
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero-container {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    margin: 0 auto;
    padding-top: 10px;
}

/* Floating bubble background */
.hero-background {
    position: absolute;
    left: 0; right: 0; top: 0; bottom: 0;
    z-index: 1;
    pointer-events: none;
}

.hero-shape {
    position: absolute;
    border-radius: 50%;
    background: transparent;
    border: 2px solid rgba(255,255,255,0.55);
    box-shadow:
        0 0 22px rgba(255,255,255,0.18),
        inset 0 0 14px rgba(255,255,255,0.08);
    opacity: 0.38;
    will-change: transform;
    animation: rise 14s linear infinite alternate, sway 6s ease-in-out infinite alternate;
}

.hero-shape-1 {
    width: 240px;
    height: 240px;
    left: -50px;
    top: 40px;
    border-color: rgba(167,139,250,0.6);
    box-shadow:
        0 0 24px rgba(167,139,250,0.25),
        inset 0 0 16px rgba(167,139,250,0.15);
    animation-duration: 16s, 7s;
}

.hero-shape-2 {
    width: 300px;
    height: 300px;
    right: -70px;
    top: -50px;
    border-color: rgba(96,165,250,0.55);
    box-shadow:
        0 0 26px rgba(96,165,250,0.25),
        inset 0 0 18px rgba(96,165,250,0.14);
    animation-duration: 18s, 8s;
    animation-delay: 0.6s, 0.2s;
}

.hero-shape-3 {
    width: 180px;
    height: 180px;
    left: 50%;
    bottom: -70px;
    transform: translateX(-50%);
    border-color: rgba(251,146,60,0.55);
    box-shadow:
        0 0 22px rgba(251,146,60,0.22),
        inset 0 0 14px rgba(251,146,60,0.12);
    animation-duration: 14s, 6.5s;
    animation-delay: 0.3s, 0s;
}

@keyframes rise {
    from { transform: translateY(0) }
    to   { transform: translateY(-90px) }
}

@keyframes sway {
    0%   { transform: translateX(0) }
    50%  { transform: translateX(16px) }
    100% { transform: translateX(-6px) }
}

.hero-profile {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.hero-profile-image {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    object-fit: cover;
    border: 6px solid rgba(255,255,255,0.85);
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}

.hero-title {
    font-size: 2.6rem;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.hero-subtitle {
    margin-top: 8px;
    font-size: 1.1rem;
    opacity: 0.95;
}

.hero-description {
    margin: 16px auto 22px;
    max-width: 700px;
    opacity: 0.95;
}

.hero-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 22px;
    border-radius: 10px;
    border: 1px solid transparent;
    cursor: pointer;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease, border-color 0.2s ease;
}

.btn-primary {
    background: #fff;
    color: #3c4b6e;
}

.btn-primary:hover,
.btn-primary:focus {
    background: var(--gradient-primary);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 8px 18px rgba(102,126,234,0.30);
    transform: translateY(-1px);
}

.btn-secondary {
    background: transparent;
    color: #fff;
    border-color: rgba(255,255,255,0.8);
}

.btn-secondary:hover,
.btn-secondary:focus {
    background: rgba(255,255,255,0.1);
    transform: translateY(-1px);
}

/* Download buttons (notes and certifications) */
.btn-download {
    background: #eef2ff;
    color: #3730a3;
    border: 1px solid #e0e7ff;
}

.btn-download:hover,
.btn-download:focus {
    background: var(--gradient-primary);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 8px 18px rgba(102,126,234,0.30);
    transform: translateY(-1px);
}

/* Sections */
section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 30px;
    font-size: 2rem;
}

/* About */
.about {
    background: #fff;
    border-top: 1px solid #eef0f3;
    border-bottom: 1px solid #eef0f3;
}

.about-content {
    max-width: 900px;
    margin: 0 auto;
}

.about-text p {
    margin-bottom: 12px;
}

.skills-grid {
    margin-top: 18px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
}

.skill-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f3f6fd;
    border: 1px solid #e6ecfb;
    padding: 10px 12px;
    border-radius: 10px;
}

/* Projects */
.projects {
    background: #fff;
}

.project-filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin: 10px 0 24px;
}

.filter-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 10px;
    border: 1px solid #e1e6f3;
    background: #f7f9ff;
    color: #2c3e50;
    cursor: pointer;
    font-weight: 600;
}

.filter-btn.active,
.filter-btn:hover {
    background: #4f8bff;
    border-color: #4f8bff;
    color: #fff;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
}

.project-card {
    background: var(--gradient-primary);
    color: #fff;
    border: none;
    border-radius: 14px;
    padding: 0;
    height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--shadow-primary-soft);
    transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.2s ease;
    position: relative;
    overflow: hidden;
}

.project-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-primary);
}

.project-image {
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    border-radius: 14px;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 14px;
}

.project-image i {
    font-size: 64px;
    color: #ffffff;
    opacity: 0.95;
}

.project-content {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 12px 14px;
    background: linear-gradient(to top, rgba(0,0,0,0.55), rgba(0,0,0,0.0));
    color: #fff;
    display: flex;
    align-items: flex-end;
    min-height: 56px;
}

.project-content h3 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    text-shadow: 0 2px 6px rgba(0,0,0,0.35);
}

/* Show only the title in overlay */
.project-content > *:not(h3) { display: none !important; }

.project-tech {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tech-tag {
    background: #f0f4ff;
    color: #2b3e6b;
    border: 1px solid #e0e7ff;
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 0.85rem;
}

/* Certifications */
.certifications {
    background: #fff;
}

.certifications-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
}

.cert-card {
    background: #ffffff;
    border: 1px solid #e7ebf5;
    border-radius: 14px;
    padding: 18px;
    display: grid;
    grid-template-columns: 56px 1fr;
    gap: 14px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.cert-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 26px rgba(102,126,234,0.18);
    border-color: #dbe4ff;
}

.cert-card::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -60%;
    width: 50%;
    height: 200%;
    background: linear-gradient(120deg, rgba(255,255,255,0.0) 0%, rgba(255,255,255,0.35) 50%, rgba(255,255,255,0.0) 100%);
    transform: rotate(20deg) translateX(-120%);
    transition: transform 0.6s ease;
    pointer-events: none;
}

.cert-card:hover::after { transform: rotate(20deg) translateX(220%); }

.cert-icon {
    display: grid;
    place-items: center;
    font-size: 24px;
    color: #ff7a59;
    transition: transform 0.2s ease, color 0.2s ease;
}

.cert-card:hover .cert-icon { transform: scale(1.1) rotate(-2deg); color: #667eea; }

.cert-card:hover .cert-content h3 { color: #667eea; }

.cert-content h3 { margin-bottom: 6px; }
.cert-date { color: #6b7a99; font-size: 0.9rem; }

/* Show only icon and title on cert cards */
.cert-content > p,
.cert-date,
.cert-details { display: none !important; }

.cert-details {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px dashed #e7ebf5;
    display: none;
}

.cert-card.show-details .cert-details { display: block; }

/* Modals */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0; top: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.45);
}

.modal-content {
    background: #fff;
    margin: 6% auto;
    padding: 20px;
    border-radius: 14px;
    border: 1px solid #e7ebf5;
    width: 92%;
    max-width: 960px;
}

.note-modal { max-width: 1000px; }

.close {
    float: right;
    font-size: 28px;
    font-weight: bold;
    color: #94a3b8;
    cursor: pointer;
}

.close:hover { color: #2c3e50; }

.project-modal-header,
.cert-modal-header,
.note-preview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #eef0f3;
}

.project-links,
.cert-actions,
.note-preview-actions { display: flex; gap: 10px; }

.cert-preview-content,
.note-preview-content { border: 1px solid #eef0f3; border-radius: 10px; overflow: hidden; background: #fafbfe; }

.cert-preview-content iframe,
.note-preview-content iframe { display: block; width: 100%; height: 520px; border: 0; }

/* Modal tags styling */
.project-modal-body { display: grid; gap: 14px; }
.modal-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.modal-tags .tech-tag {
    background: #eef2ff;
    color: #3730a3;
    border: 1px solid #e0e7ff;
}

/* Notes section cards */
.notes { background: #fff; }

.notes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
}

.note-card {
    background: var(--gradient-primary);
    color: #fff;
    border: none;
    border-radius: 14px;
    padding: 0;
    height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-primary-soft);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.note-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-primary);
}

.note-icon {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-size: 56px;
    color: rgba(255,255,255,0.95);
}

.note-content {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    padding: 12px 14px;
    background: linear-gradient(to top, rgba(0,0,0,0.55), rgba(0,0,0,0.0));
    min-height: 56px;
    display: flex;
    align-items: flex-end;
}

.note-content h3 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    text-shadow: 0 2px 6px rgba(0,0,0,0.35);
}

/* Hide extra info/buttons on the card; show in modal */
.note-content p,
.note-meta,
.note-actions { display: none !important; }

/* Footer */
.footer {
    background: #0f172a;
    color: #cbd5e1;
}

.footer .footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

.footer h3 { color: #fff; margin-bottom: 10px; }
.social-links a { color: #cbd5e1; margin-right: 12px; font-size: 1.2rem; }
.social-links a:hover { color: #fff; }

.footer-bottom {
    margin-top: 16px;
    padding-top: 10px;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    font-size: 0.95rem;
}

/* Responsive */
@media (max-width: 900px) {
    .hero-title { font-size: 2.2rem; }
}

@media (max-width: 768px) {
    .nav-menu {
        position: absolute;
        top: 70px;
        right: 0;
        left: 0;
        background: #fff;
        border-bottom: 1px solid #eef0f3;
        display: none;
        flex-direction: column;
        gap: 0;
    }
    .nav-menu.active { display: flex; }
    .nav-item { border-top: 1px solid #eef0f3; }
    .nav-link { padding: 14px 20px; display: block; }
    .hamburger { display: flex; }

    .hero { padding: 120px 0 60px; }
    .hero-profile-image { width: 130px; height: 130px; }
    .hero-shape-1 { width: 180px; height: 180px; left: -70px; top: 20px; }
    .hero-shape-2 { width: 220px; height: 220px; right: -70px; top: -60px; }
    .hero-shape-3 { width: 140px; height: 140px; bottom: -60px; }

    .projects-grid,
    .certifications-grid { grid-template-columns: 1fr; }

    .cert-preview-content iframe,
    .note-preview-content iframe { height: 360px; }
}


