:root {
    --bg: #050816;
    --bg-alt: #0b1020;
    --accent: #6366f1;
    --accent-soft: rgba(99, 102, 241, 0.12);
    --text-main: #e5e7eb;
    --text-muted: #9ca3af;
    --card-bg: #111827;
    --border-subtle: rgba(156, 163, 175, 0.2);
    --danger: #ef4444;

    --radius-lg: 18px;
    --radius-md: 12px;
    --radius-pill: 999px;

    --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.75);
    --shadow-subtle: 0 10px 30px rgba(15, 23, 42, 0.45);
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: radial-gradient(circle at top left, #1d1b3f 0, #020617 45%, #000 100%);
    color: var(--text-main);
    line-height: 1.6;
}

/* Layout */

.container {
    width: min(1120px, 100% - 2.5rem);
    margin: 0 auto;
}

.section {
    padding: 6rem 0;
}

.section-alt {
    background: radial-gradient(circle at top, #020617 0, #020617 30%, #000 100%);
}

.section-container {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 1.5rem;
}

.section-header h2 {
    font-size: clamp(1.9rem, 3vw, 2.2rem);
    font-weight: 600;
    margin-bottom: 0.35rem;
}

.section-header p {
    color: var(--text-muted);
    font-size: 0.98rem;
}

/* Header / Navbar */

.header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(20px);
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.95), rgba(15, 23, 42, 0.85), transparent);
    border-bottom: 1px solid rgba(148, 163, 184, 0.28);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 0;
}

.logo a {
    color: #f9fafb;
    font-weight: 700;
    letter-spacing: 0.18em;
    font-size: 1.1rem;
    text-decoration: none;
    text-transform: uppercase;
}

.logo span {
    color: var(--accent);
}

.nav {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    font-size: 0.9rem;
}

.nav a {
    color: var(--text-muted);
    text-decoration: none;
    position: relative;
    transition: color 0.2s ease;
}

.nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -0.25rem;
    width: 0;
    height: 2px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent), #a855f7);
    transition: width 0.22s ease;
}

.nav a:hover {
    color: var(--text-main);
}

.nav a:hover::after {
    width: 100%;
}

/* Burger */

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 0.22rem;
    background: none;
    border: none;
    cursor: pointer;
}

.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: #e5e7eb;
    border-radius: 999px;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

/* Hero */

.hero {
    padding-top: 4.5rem;
    padding-bottom: 5rem;
}

.hero-container {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(0, 1.1fr);
    gap: 3.5rem;
    align-items: center;
}

.hero-intro {
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.22em;
    color: #a5b4fc;
    margin-bottom: 0.5rem;
}

.hero-title {
    font-size: clamp(2.2rem, 4vw, 2.8rem);
    font-weight: 700;
    letter-spacing: 0.03em;
    margin-bottom: 0.4rem;
}

.hero-subtitle {
    color: var(--text-muted);
    font-size: 0.98rem;
    margin-bottom: 1rem;
}

.hero-description {
    color: #e2e8f0;
    font-size: 0.98rem;
    max-width: 500px;
    margin-bottom: 1.5rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1.6rem;
    border-radius: var(--radius-pill);
    border: 1px solid transparent;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.primary-btn {
    background: linear-gradient(135deg, var(--accent), #a855f7);
    color: #f9fafb;
    box-shadow: var(--shadow-soft);
}

.primary-btn:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 20px 50px rgba(79, 70, 229, 0.6);
}

.secondary-btn {
    color: var(--accent);
    border-color: rgba(129, 140, 248, 0.6);
    background: rgba(15, 23, 42, 0.85);
}

.secondary-btn:hover {
    background: rgba(30, 64, 175, 0.3);
    color: #e5e7eb;
    transform: translateY(-1px);
    box-shadow: var(--shadow-subtle);
}

.hero-social {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.hero-social a {
    width: 2.4rem;
    height: 2.4rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.5);
    color: #e5e7eb;
    font-size: 1.1rem;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.hero-social a:hover {
    background: var(--accent-soft);
    color: #e0e7ff;
    border-color: var(--accent);
    transform: translateY(-1px) scale(1.03);
    box-shadow: 0 10px 26px rgba(79, 70, 229, 0.55);
}

/* Hero image */

.hero-image {
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-circle {
    width: 210px;
    height: 210px;
    border-radius: 999px;
    background: radial-gradient(circle at 20% 0, #4f46e5, #0f172a 55%);
    border: 2px solid rgba(129, 140, 248, 0.6);
    box-shadow: 0 18px 45px rgba(30, 64, 175, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.profile-circle span {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: #e5e7eb;
}

/* Subtle orbiting ring */

.profile-circle::after {
    content: "";
    position: absolute;
    width: 260px;
    height: 260px;
    border-radius: inherit;
    border: 1px dashed rgba(148, 163, 184, 0.4);
    box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.9);
}

/* About */

.about-content {
    max-width: 720px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    color: #e5e7eb;
    font-size: 0.97rem;
}

/* Skills */

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 1.75rem;
}

.skills-group {
    background: linear-gradient(145deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.9));
    border-radius: var(--radius-lg);
    padding: 1.4rem 1.5rem;
    border: 1px solid var(--border-subtle);
    box-shadow: var(--shadow-subtle);
}

.skills-group h3 {
    font-size: 1.05rem;
    margin-bottom: 0.75rem;
}

.skills-group ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.skills-group li {
    font-size: 0.85rem;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.3);
    color: #e5e7eb;
    background: rgba(15, 23, 42, 0.95);
}

/* Cards (Projects & Certificates) */

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
}

.card {
    background: radial-gradient(circle at top left, #1e293b 0, #020617 55%);
    border-radius: var(--radius-lg);
    padding: 1.4rem 1.5rem 1.5rem;
    border: 1px solid rgba(148, 163, 184, 0.35);
    box-shadow: var(--shadow-subtle);
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, rgba(129, 140, 248, 0.28), transparent 55%);
    opacity: 0;
    transition: opacity 0.22s ease;
    pointer-events: none;
}

.card:hover::before {
    opacity: 1;
}

.card h3 {
    font-size: 1.02rem;
    font-weight: 600;
}

.card-tag {
    font-size: 0.8rem;
    color: #a5b4fc;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.card-text {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.card-link {
    margin-top: 0.4rem;
    font-size: 0.9rem;
    color: #c4b5fd;
    text-decoration: none;
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding-bottom: 0.02rem;
    border-bottom: 1px solid transparent;
    transition: color 0.16s ease, border-color 0.16s ease, transform 0.16s ease;
}

.card-link::after {
    content: "↗";
    font-size: 0.8rem;
    transform: translateY(1px);
}

.card-link:hover {
    color: #e0e7ff;
    border-color: rgba(196, 181, 253, 0.8);
    transform: translateY(-1px);
}

/* Contact */

.contact-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.2fr);
    gap: 2.2rem;
    align-items: flex-start;
}

.contact-info {
    background: linear-gradient(150deg, rgba(15, 23, 42, 0.96), rgba(30, 64, 175, 0.65));
    border-radius: var(--radius-lg);
    padding: 1.6rem 1.6rem 1.7rem;
    border: 1px solid rgba(129, 140, 248, 0.4);
    box-shadow: var(--shadow-soft);
}

.contact-info h3 {
    margin-bottom: 0.6rem;
}

.contact-info p {
    font-size: 0.9rem;
    color: #e5e7eb;
    margin-bottom: 0.25rem;
}

.contact-social {
    margin-top: 0.6rem;
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.contact-social a {
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(191, 219, 254, 0.6);
    color: #e0f2fe;
    font-size: 1.02rem;
    background: rgba(15, 23, 42, 0.75);
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.18s ease;
}

.contact-social a:hover {
    background: rgba(37, 99, 235, 0.85);
    border-color: #bfdbfe;
    transform: translateY(-1px);
}

.contact-form {
    background: rgba(15, 23, 42, 0.98);
    border-radius: var(--radius-lg);
    padding: 1.5rem 1.5rem 1.6rem;
    border: 1px solid var(--border-subtle);
    box-shadow: var(--shadow-subtle);
}

.contact-form h3 {
    margin-bottom: 0.9rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    margin-bottom: 0.85rem;
}

.form-group label {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.form-group input,
.form-group textarea {
    background: rgba(15, 23, 42, 0.98);
    border-radius: 0.75rem;
    border: 1px solid rgba(148, 163, 184, 0.6);
    color: var(--text-main);
    padding: 0.6rem 0.8rem;
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: rgba(148, 163, 184, 0.9);
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 1px rgba(129, 140, 248, 0.55);
    background: rgba(15, 23, 42, 0.98);
}

.contact-form .btn {
    margin-top: 0.2rem;
    opacity: 0.7;
    cursor: not-allowed;
}

.form-note {
    margin-top: 0.45rem;
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* Footer */

.footer {
    padding: 1.4rem 0 2rem;
    border-top: 1px solid rgba(30, 41, 59, 0.95);
    background: radial-gradient(circle at top, #020617 0, #000 100%);
}

.footer-container {
    text-align: center;
    font-size: 0.82rem;
    color: rgba(148, 163, 184, 0.9);
}

/* Responsive */

@media (max-width: 900px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: left;
    }

    .hero-image {
        order: -1;
        margin-bottom: 1.3rem;
    }

    .hero-description {
        max-width: none;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav {
        position: fixed;
        inset: 0 0 auto;
        top: 3.3rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.85rem;
        background: radial-gradient(circle at top, rgba(15, 23, 42, 0.98), rgba(15, 23, 42, 0.98));
        padding: 1rem 1.25rem 1.4rem;
        border-bottom: 1px solid rgba(30, 64, 175, 0.7);
        transform: translateY(-120%);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.24s ease, opacity 0.24s ease;
    }

    .nav.open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }

    .nav-toggle {
        display: flex;
    }

    .hero {
        padding-top: 3.7rem;
    }

    .section {
        padding: 4.5rem 0;
    }
}

/* Burger animation */

.nav-toggle.open span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.nav-toggle.open span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.open span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}
