/* 
   Theme: Calm Tech / Purple Mint
   Dark mode toggle via [data-theme] attribute on <html>
*/

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Sora:wght@600;700;800&display=swap');

/* DESIGN TOKENS
   Dark mode is default. Light applied via [data-theme="light"].
*/

:root {
    /* Dark Mode Tokens (default) */
    --primary: #A78BFA;
    --primary-hover: #9474EB;
    --primary-glow: rgba(167, 139, 250, 0.25);
    --secondary: #5EEAD4;
    --accent-mint: #5EEAD4;
    --accent-surface: #1E1B2E;
    --bg-main: #0D0B14;
    --bg-subtle: #13111D;
    --surface: #1A1726;
    --surface-glass: rgba(26, 23, 38, 0.78);
    --surface-hover: #242038;
    --border: rgba(167, 139, 250, 0.15);
    --border-glow: rgba(167, 139, 250, 0.12);
    --text-primary: #EDEBF4;
    --text-secondary: #A09BB5;

    /* System Tokens */
    --font-heading: 'Sora', sans-serif;
    --font-body: 'Inter', sans-serif;
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-full: 50px;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 8px 32px rgba(0, 0, 0, 0.35);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.45);
    --shadow-glow: 0 0 40px var(--primary-glow);
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);

    /* Gradients */
    --grad-primary-right: linear-gradient(135deg, #A78BFA, #5EEAD4);
    --grad-primary-down: linear-gradient(to bottom, #A78BFA, #5EEAD4);
    --grad-purple: linear-gradient(135deg, #8B6FE0, #A78BFA);
    --grad-mint: linear-gradient(135deg, #3DD4BE, #5EEAD4);
    --grad-hero: linear-gradient(135deg, #0D0B14 0%, #1A1726 50%, #151220 100%);
    --grad-card-border: linear-gradient(135deg, rgba(167, 139, 250, 0.3), rgba(94, 234, 212, 0.12));
}

[data-theme="light"] {
    /* Light Mode Tokens */
    --primary: #7C5CCA;
    --primary-hover: #6A4BB5;
    --primary-glow: rgba(124, 92, 202, 0.2);
    --secondary: #14B8A6;
    --accent-mint: #14B8A6;
    --accent-surface: #F0ECFA;
    --bg-main: #FAF8FF;
    --bg-subtle: #F0ECFA;
    --surface: #FFFFFF;
    --surface-glass: rgba(255, 255, 255, 0.82);
    --surface-hover: #F5F2FC;
    --border: rgba(124, 92, 202, 0.15);
    --border-glow: rgba(124, 92, 202, 0.12);
    --text-primary: #1A1726;
    --text-secondary: #5A5370;

    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 8px 32px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.08);
    --shadow-glow: 0 0 40px var(--primary-glow);

    --grad-primary-right: linear-gradient(135deg, #7C5CCA, #14B8A6);
    --grad-primary-down: linear-gradient(to bottom, #7C5CCA, #14B8A6);
    --grad-purple: linear-gradient(135deg, #6A4BB5, #7C5CCA);
    --grad-mint: linear-gradient(135deg, #0D9488, #14B8A6);
    --grad-hero: linear-gradient(135deg, #FAF8FF 0%, #F5F0FF 50%, #FAF8FF 100%);
    --grad-card-border: linear-gradient(135deg, rgba(124, 92, 202, 0.35), rgba(20, 184, 166, 0.15));
}

/* RESET & BASE */

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.7;
    overflow-x: hidden;
    transition: background-color var(--transition), color var(--transition);
    min-height: 100vh;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--text-primary);
    line-height: 1.2;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

p {
    margin-bottom: 1.25rem;
    color: var(--text-secondary);
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-hover);
}

:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 4px;
    border-radius: 4px;
}

img {
    max-width: 100%;
    height: auto;
}

/* LAYOUT */

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

section {
    padding: 100px 0;
}

/* UTILITIES & EFFECTS */

/* Glassmorphism — warm-toned, subtle */
.glass {
    background: var(--surface-glass);
    backdrop-filter: blur(16px) saturate(1.2);
    -webkit-backdrop-filter: blur(16px) saturate(1.2);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-md);
}

/* Gradient text */
.text-gradient {
    background: var(--grad-primary-right);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

/* Animated gradient border — used on cards for a premium feel */
.glow-border {
    position: relative;
    border: none;
    overflow: hidden;
}

.glow-border::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: var(--grad-card-border);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

/* Scroll-reveal animation */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger children animations */
.stagger>* {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.stagger.visible>*:nth-child(1) {
    transition-delay: 0.1s;
    opacity: 1;
    transform: translateY(0);
}

.stagger.visible>*:nth-child(2) {
    transition-delay: 0.2s;
    opacity: 1;
    transform: translateY(0);
}

.stagger.visible>*:nth-child(3) {
    transition-delay: 0.3s;
    opacity: 1;
    transform: translateY(0);
}

.stagger.visible>*:nth-child(4) {
    transition-delay: 0.4s;
    opacity: 1;
    transform: translateY(0);
}

.stagger.visible>*:nth-child(5) {
    transition-delay: 0.5s;
    opacity: 1;
    transform: translateY(0);
}

.stagger.visible>*:nth-child(6) {
    transition-delay: 0.6s;
    opacity: 1;
    transform: translateY(0);
}

/* Scroll Progress Bar */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--grad-primary-right);
    z-index: 2000;
    pointer-events: none;
    transition: width 0.1s ease-out;
}

/* Toast Notification System */
.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 3000;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    pointer-events: none;
}

.toast {
    background: var(--surface-glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 300px;
    max-width: 450px;
    color: var(--text-primary);
    pointer-events: auto;
    animation: toast-in 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.toast.removing {
    transform: translateX(100%);
    opacity: 0;
}

.toast-icon {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

.toast-success .toast-icon {
    color: var(--secondary);
}

.toast-error .toast-icon {
    color: #F87171;
}

.toast-info .toast-icon {
    color: var(--primary);
}

.toast-content {
    font-size: 0.9rem;
    font-weight: 500;
}

@keyframes toast-in {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* BUTTONS */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 14px 32px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: var(--transition);
    font-family: var(--font-body);
    font-size: 0.95rem;
    letter-spacing: 0.01em;
    text-decoration: none;
}

.btn-primary {
    background: var(--grad-purple);
    color: #FFFFFF;
    box-shadow: 0 4px 16px var(--primary-glow);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px var(--primary-glow);
    color: #FFFFFF;
}

.btn-secondary {
    background: var(--surface);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--surface-hover);
    transform: translateY(-3px);
    color: var(--text-primary);
}

.btn:disabled {
    opacity: 0.6;
    pointer-events: none;
    filter: grayscale(0.5);
    transform: none !important;
}

.btn-loading {
    position: relative;
    color: transparent !important;
}

.btn-loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-top: -10px;
    margin-left: -10px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spinner 0.8s linear infinite;
}

@keyframes spinner {
    to {
        transform: rotate(360deg);
    }
}

/* NAVIGATION */

header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1rem 0;
}

nav {
    display: flex;
    justify-content: center;
    align-items: center;
}

.navbar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    list-style: none;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-full);
}

.navbar li a {
    font-weight: 500;
    color: var(--text-secondary);
    font-size: 0.9rem;
    padding: 0.5rem 1.25rem;
    border-radius: var(--radius-full);
    transition: var(--transition);
    display: inline-block;
}

.navbar li a:hover {
    color: var(--text-primary);
    background: rgba(167, 139, 250, 0.08);
}

.navbar li a.active {
    color: var(--primary);
    background: rgba(167, 139, 250, 0.12);
}

/* Theme toggle button inside navbar */
.theme-toggle {
    background: none;
    border: 1px solid var(--border);
    color: var(--text-secondary);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    margin-left: 0.5rem;
    flex-shrink: 0;
}

.theme-toggle:hover {
    color: var(--primary);
    border-color: var(--primary);
    background: rgba(167, 139, 250, 0.08);
}

/* Show/hide sun/moon icons */
.theme-toggle .icon-sun {
    display: none;
}

.theme-toggle .icon-moon {
    display: block;
}

[data-theme="light"] .theme-toggle .icon-sun {
    display: block;
}

[data-theme="light"] .theme-toggle .icon-moon {
    display: none;
}

/* HERO SECTION */

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 100px;
    padding-bottom: 60px;
    position: relative;
    overflow: hidden;
}

/* Ambient glow orbs behind hero */
.hero::before,
.hero::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.4;
    pointer-events: none;
    animation: float 8s ease-in-out infinite;
}

.hero::before {
    width: 500px;
    height: 500px;
    background: var(--primary);
    top: -100px;
    right: -150px;
    opacity: 0.08;
}

.hero::after {
    width: 400px;
    height: 400px;
    background: var(--secondary);
    bottom: -100px;
    left: -100px;
    opacity: 0.06;
    animation-delay: 4s;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0) scale(1);
    }

    50% {
        transform: translateY(-30px) scale(1.05);
    }
}

.hero-content {
    max-width: 750px;
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: clamp(2.5rem, 7vw, 4rem);
    margin-bottom: 1.5rem;
    font-weight: 800;
}

.hero p {
    font-size: 1.15rem;
    max-width: 550px;
    margin: 0 auto 2.5rem;
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Profile image with animated ring */
.profile-img-container {
    margin-bottom: 2.5rem;
    position: relative;
    display: inline-block;
}

.profile-img-container::before {
    content: '';
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    background: var(--grad-primary-right);
    opacity: 0.6;
    animation: pulse-ring 3s ease-in-out infinite;
}

@keyframes pulse-ring {

    0%,
    100% {
        opacity: 0.4;
        transform: scale(1);
    }

    50% {
        opacity: 0.7;
        transform: scale(1.03);
    }
}

.profile-img {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    object-fit: cover;
    position: relative;
    z-index: 1;
    border: 4px solid var(--bg-main);
    box-shadow: var(--shadow-lg);
}

/* PAGE HERO (About, Projects, Contact) */

.page-hero {
    padding-top: 140px;
    padding-bottom: 40px;
    text-align: center;
    position: relative;
}

.page-hero h1 {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    margin-bottom: 1rem;
}

.page-hero p {
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.8;
}

/* ABOUT GRID & CARDS */

.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    padding-top: 0;
    padding-bottom: 100px;
}

.about-card {
    padding: 2rem;
    border-radius: var(--radius-md);
    transition: var(--transition);
    position: relative;
}

.about-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg), var(--shadow-glow);
}

.about-card h3 {
    color: var(--primary);
    font-size: 1.15rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.about-card h3 .card-icon {
    width: 20px;
    height: 20px;
    opacity: 0.8;
}

/* SKILLS */

.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill-tag {
    background: rgba(167, 139, 250, 0.1);
    color: var(--primary);
    padding: 6px 14px;
    border-radius: var(--radius-full);
    font-size: 0.82rem;
    font-weight: 500;
    border: 1px solid rgba(167, 139, 250, 0.2);
    transition: var(--transition);
}

.skill-tag:hover {
    background: rgba(167, 139, 250, 0.18);
    transform: translateY(-1px);
}

[data-theme="light"] .skill-tag {
    background: rgba(124, 92, 202, 0.08);
    color: #6A4BB5;
    border-color: rgba(124, 92, 202, 0.2);
}

[data-theme="light"] .skill-tag:hover {
    background: rgba(124, 92, 202, 0.15);
}

/* PROJECT CARDS */

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    padding-top: 0;
    padding-bottom: 100px;
}

.project-card {
    border-radius: var(--radius-md);
    transition: var(--transition);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg), var(--shadow-glow);
}

/* Top accent bar on each card */
.project-card-accent {
    height: 3px;
    background: var(--grad-primary-right);
    opacity: 0.6;
    transition: var(--transition);
}

.project-card:hover .project-card-accent {
    opacity: 1;
    height: 4px;
}

.project-card-content {
    padding: 2rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.project-card h2 {
    font-size: 1.3rem;
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.project-card p {
    flex-grow: 1;
    font-size: 0.92rem;
    line-height: 1.7;
}

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

/* CONTACT FORM */

.contact-form-wrapper {
    max-width: 560px;
    margin: 0 auto;
    padding-bottom: 100px;
}

.contact-form {
    padding: 2.5rem;
    border-radius: var(--radius-md);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg-subtle);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: var(--transition);
    outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-secondary);
    opacity: 0.6;
}

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

/* FOOTER */

footer {
    padding: 48px 0;
    background: var(--surface);
    text-align: center;
    border-top: 1px solid var(--border);
}

footer p {
    font-size: 0.85rem;
    margin-bottom: 0;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.social-links a {
    color: var(--text-secondary);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid var(--border);
}

.social-links a:hover {
    color: var(--primary);
    border-color: var(--primary);
    background: rgba(167, 139, 250, 0.08);
    transform: translateY(-2px);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.footer-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.cv-link {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 8px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    transition: var(--transition);
}

.cv-link:hover {
    background: rgba(167, 139, 250, 0.08);
    transform: translateY(-2px);
}

/* Timeline & Certifications */

.timeline {
    position: relative;
    max-width: 800px;
    margin: 40px auto;
    padding: 20px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

.timeline-item {
    position: relative;
    padding-left: 60px;
    margin-bottom: 40px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 14px;
    top: 0;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--primary);
    border: 4px solid var(--bg-main);
    z-index: 1;
}

.timeline-date {
    display: block;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.timeline-content h3 {
    margin-bottom: 0.25rem;
    font-size: 1.25rem;
}

.timeline-content .company {
    display: block;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.timeline-content ul {
    list-style: none;
}

.timeline-content li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.92rem;
}

.timeline-content li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--primary);
}

.certs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 3rem;
}

.cert-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.cert-card h4 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.cert-issuer {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 1.25rem;
    display: block;
}

.credly-embed-container {
    background: #fff;
    padding: 10px;
    border-radius: var(--radius-sm);
    display: inline-block;
    margin-top: auto;
}

[data-theme="dark"] .cert-card img.themed-logo-light,
[data-theme="light"] .cert-card img.themed-logo-dark {
    display: none;
}

/* Interests / Hobbies */

.interests-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.interest-card {
    text-align: center;
    padding: 2rem 1.5rem;
    transition: transform 0.2s ease;
}

.interest-card:hover {
    transform: translateY(-4px);
}

.interest-icon {
    font-size: 2.5rem;
    display: block;
    margin-bottom: 0.75rem;
}

.interest-card h4 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.interest-card p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.project-preview-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-bottom: 1px solid var(--border);
}

.project-card .themed-logo {
    height: 40px;
    width: auto;
    margin-bottom: 1rem;
    object-fit: contain;
}

[data-theme="dark"] .project-card .themed-logo-light,
[data-theme="light"] .project-card .themed-logo-dark {
    display: none;
}

/* Interactive Terminal */

.terminal-page {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 6rem 1rem 2rem;
    min-height: calc(100vh - 160px);
}

.terminal-container {
    width: 100%;
    max-width: 860px;
    background: #0a0a14;
    border: 1px solid rgba(167, 139, 250, 0.2);
    border-radius: var(--radius-md);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    cursor: text;
}

.terminal-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background: #141420;
    border-bottom: 1px solid rgba(167, 139, 250, 0.1);
}

.terminal-dots {
    display: flex;
    gap: 6px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot-red {
    background: #ff5f57;
}

.dot-yellow {
    background: #febc2e;
}

.dot-green {
    background: #28c840;
}

.terminal-title {
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    font-size: 0.75rem;
    color: #888;
}

.terminal-body {
    padding: 1rem 1.25rem;
    overflow-y: auto;
    max-height: 55vh;
    scrollbar-width: thin;
    scrollbar-color: rgba(167, 139, 250, 0.3) transparent;
}

.terminal-body::-webkit-scrollbar {
    width: 6px;
}

.terminal-body::-webkit-scrollbar-thumb {
    background: rgba(167, 139, 250, 0.3);
    border-radius: 3px;
}

.terminal-input-row {
    display: flex;
    align-items: center;
    padding: 0.75rem 1.25rem 1rem;
    border-top: 1px solid rgba(167, 139, 250, 0.05);
}

.terminal-prompt {
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    font-size: 0.85rem;
    color: #5eead4;
    white-space: nowrap;
    flex-shrink: 0;
}

.terminal-input {
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    font-size: 0.85rem;
    color: #e2e8f0;
    background: transparent;
    border: none;
    outline: none;
    flex: 1;
    caret-color: #5eead4;
}

.terminal-input::placeholder {
    color: #444;
}

/* Terminal output lines */

.terminal-line {
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    font-size: 0.8rem;
    line-height: 1.6;
    color: #c8d0dc;
    white-space: pre-wrap;
    word-break: break-word;
}

.terminal-line a {
    color: #a78bfa;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.terminal-line a:hover {
    color: #5eead4;
}

.terminal-input-echo .terminal-cmd {
    color: #e2e8f0;
}

.terminal-welcome {
    color: #888;
}

.ascii-art {
    color: #a78bfa;
    font-size: 0.9rem;
    font-weight: bold;
    line-height: 1.4;
    overflow-x: auto;
}

/* Konami Mode */

.terminal-container.konami-mode {
    border-color: #00ff41;
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.2);
    position: relative;
}

.terminal-container.konami-mode::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%,
            rgba(0, 0, 0, 0.1) 50%), linear-gradient(90deg,
            rgba(255, 0, 0, 0.03),
            rgba(0, 255, 0, 0.01),
            rgba(0, 0, 255, 0.03));
    background-size: 100% 3px, 3px 100%;
    pointer-events: none;
    z-index: 10;
}

.konami-mode .terminal-prompt {
    color: #00ff41;
}

.konami-mode .terminal-line {
    color: #00ff41;
    text-shadow: 0 0 5px rgba(0, 255, 65, 0.5);
}

.konami-mode .ascii-art {
    color: #00ff41;
}

.konami-mode .terminal-line a {
    color: #00ff41;
    text-decoration: underline;
}

.konami-mode .terminal-input {
    color: #00ff41;
    caret-color: #00ff41;
}

/* RESPONSIVENESS */


@media (max-width: 768px) {
    section {
        padding: 60px 0;
    }

    .navbar {
        gap: 0.25rem;
        padding: 0.4rem 0.5rem;
    }

    .navbar li a {
        padding: 0.4rem 0.8rem;
        font-size: 0.82rem;
    }

    .navbar li a[href="playground.html"] {
        display: none;
    }

    .theme-toggle {
        width: 34px;
        height: 34px;
    }

    .hero h1 {
        font-size: clamp(2rem, 8vw, 3rem);
    }

    .profile-img {
        width: 130px;
        height: 130px;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .about-grid,
    .projects-grid {
        grid-template-columns: 1fr;
    }

    .contact-form {
        padding: 1.5rem;
    }

    .page-hero {
        padding-top: 120px;
    }
}

@media (max-width: 375px) {
    .navbar {
        gap: 0;
        padding: 0.3rem;
    }

    .navbar li a {
        padding: 0.35rem 0.6rem;
        font-size: 0.78rem;
    }
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }

    .stagger>* {
        opacity: 1;
        transform: none;
    }
}