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

:root {
    --primary-dark: #0a0a0a;
    --secondary-dark: #1a1a1a;
    --accent-blue: #00d4ff;
    --accent-purple: #6366f1;
    --text-light: #ffffff;
    --text-muted: #a0a0a0;
    --gradient-1: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-2: linear-gradient(135deg, #00d4ff 0%, #6366f1 100%);
    --gradient-3: linear-gradient(135deg, #667eea 0%, #00d4ff 100%);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--primary-dark);
    color: var(--text-light);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Navigation */
nav {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: auto;
    max-width: 1000px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50px;
    z-index: 1000;
    padding: 0.8rem 2rem;
    transition: all 0.3s ease;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

nav.scrolled {
    background: rgba(255, 255, 255, 0.15); /* Slightly more opaque when scrolled */
    box-shadow: 0 8px 32px rgba(0, 212, 255, 0.1), 0 2px 20px rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
}

.nav-container {
    max-width: none;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0; /* Remove padding to prevent double padding */
}

.nav-container .logo {
    display: none;
}

.logo {
    position: fixed;
    top: 25px;
    left: 35px;
    z-index: 1001;
    font-size: 1.5rem;
    font-weight: bold;
    background: var(--gradient-2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    cursor: pointer;
}

.logo a {
    color: inherit;
    text-decoration: none;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 0.5rem; /* Reduce gap for compact look */
}

.nav-links a {
    color: var(--text-light);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    padding: 0.4rem 0.8rem; /* Reduce padding */
    border-radius: 25px;
    font-size: 0.85rem; /* Slightly smaller font */
    font-weight: 500;
    white-space: nowrap; /* Prevent text wrapping */
}

.nav-links a.active {
    background: transparent;
    color: white;
    box-shadow: none;
    border-bottom: 2px solid var(--accent-blue);
    border-radius: 0;
    padding-bottom: 0.2rem;
}

.nav-links a:hover {
    background: transparent;
    transform: translateY(-2px);
    box-shadow: none;
    border-bottom: 2px solid rgba(0, 212, 255, 0.5);
    border-radius: 0;
    padding-bottom: 0.2rem;
}

/* Hero Section */

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1;
}

.hero-video video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    filter: blur(2px) brightness(0.5) contrast(0.8);
    opacity: 0.6;
}

/* Update the existing .hero selector to ensure proper layering */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: radial-gradient(circle at 50% 50%, rgba(0, 212, 255, 0.1) 0%, transparent 70%);
    position: relative;
    overflow: hidden;
    transition: opacity 0.3s ease-out;
}

/* Add this media query for better mobile performance */
@media (max-width: 768px) {
    .hero-video video {
        filter: blur(1px) brightness(0.5) contrast(0.7);
        opacity: 0.4;
    }
}

/* For devices that prefer reduced motion */
@media (prefers-reduced-motion: reduce) {
    .hero-video video {
        display: none;
    }
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><radialGradient id="g" cx="50%" cy="50%"><stop offset="0%" style="stop-color:rgba(0,212,255,0.1)"/><stop offset="100%" style="stop-color:transparent"/></radialGradient></defs><circle cx="200" cy="200" r="3" fill="url(%23g)"/><circle cx="800" cy="300" r="2" fill="url(%23g)"/><circle cx="400" cy="700" r="2" fill="url(%23g)"/><circle cx="900" cy="800" r="3" fill="url(%23g)"/></svg>');
    animation: float 20s infinite linear;
}

@keyframes skillIntro {
    0% {
        opacity: 0;
        transform: scale(0.8) translateY(20px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

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

.hero h1 {
    font-size: 4rem;
    margin-bottom: 1rem;
    background: var(--gradient-2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    visibility: hidden;
    /* animation: fadeInUp 1s ease-out; */
}

.hero .subtitle {
    font-size: 1.5rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    animation: fadeInUp 1s ease-out 0.3s both;
}

.hero .description {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    line-height: 1.8;
    animation: fadeInUp 1s ease-out 0.6s both;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    animation: fadeInUp 1s ease-out 0.9s both;
}

.btn {
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: var(--gradient-2);
    color: white;
}

.btn-secondary {
    background: transparent;
    color: var(--accent-blue);
    border: 2px solid var(--accent-blue);
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3);
}

/* Sections */
.section {
    padding: 5rem 0;
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 2rem;
    padding-right: 2rem;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-align: center;
    background: var(--gradient-2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Education */
.education-item {
    background: var(--secondary-dark);
    padding: 2rem;
    border-radius: 20px;
    margin-bottom: 2rem;
    border-left: 4px solid var(--accent-blue);
    transition: all 0.3s ease;
}

.education-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 212, 255, 0.1);
}

.education-item h3 {
    color: var(--accent-blue);
    margin-bottom: 0.5rem;
}

.education-item .institution {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.education-item .grade {
    background: var(--gradient-2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 600;
}

/* Projects */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.project-card {
    background: var(--secondary-dark);
    padding: 2rem;
    border-radius: 20px;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 212, 255, 0.1);
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 212, 255, 0.15);
    border-color: var(--accent-blue);
}

.project-card h3 {
    color: var(--accent-blue);
    margin-bottom: 1rem;
}

.project-card .date {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.project-card .description {
    margin-bottom: 1rem;
    line-height: 1.6;
}

.project-card .impact {
    color: var(--accent-purple);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

/* Skills */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.skill-category {
    background: var(--secondary-dark);
    padding: 2rem;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.skill-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 212, 255, 0.1);
}

.skill-category h3 {
    color: var(--accent-blue);
    margin-bottom: 1rem;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill-tag {
    background: var(--gradient-2);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 15px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease; /* Add this line for hover effects */
}

.skill-tag:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 212, 255, 0.3);
}

/* Certifications */
.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.cert-card {
    background: var(--secondary-dark);
    padding: 2rem;
    border-radius: 20px;
    transition: all 0.3s ease;
    border-left: 4px solid var(--accent-purple);
}

.cert-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(99, 102, 241, 0.1);
}

.cert-card h3 {
    color: var(--accent-purple);
    margin-bottom: 0.5rem;
}

.cert-card .provider {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.cert-card .date {
    color: var(--accent-blue);
    font-weight: 600;
    margin-bottom: 1rem;
}

/* Achievements */
.achievement-card {
    background: var(--secondary-dark);
    padding: 2rem;
    border-radius: 20px;
    margin-bottom: 2rem;
    border: 1px solid rgba(0, 212, 255, 0.1);
    transition: all 0.3s ease;
}

.achievement-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 212, 255, 0.15);
    border-color: var(--accent-blue);
}

.achievement-card h3 {
    color: var(--accent-blue);
    margin-bottom: 1rem;
}

.achievement-card .position {
    background: var(--gradient-2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.achievement-card .date {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

/* Experience */
.experience-card {
    background: var(--secondary-dark);
    padding: 2rem;
    border-radius: 20px;
    border-left: 4px solid var(--accent-purple);
    transition: all 0.3s ease;
}

.experience-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(99, 102, 241, 0.1);
}

.experience-card h3 {
    color: var(--accent-purple);
    margin-bottom: 0.5rem;
}

.experience-card .company {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.experience-card .date {
    color: var(--accent-blue);
    font-weight: 600;
    margin-bottom: 1rem;
}

.experience-card ul {
    list-style: none;
    padding-left: 0;
}

.experience-card li {
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
}

.experience-card li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: var(--accent-blue);
}

/* Extracurriculars */
.extra-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.extra-card {
    background: var(--secondary-dark);
    padding: 2rem;
    border-radius: 20px;
    transition: all 0.3s ease;
    border: 1px solid rgba(99, 102, 241, 0.1);
}

.extra-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(99, 102, 241, 0.1);
    border-color: var(--accent-purple);
}

.extra-card h4 {
    color: var(--accent-purple);
    margin-bottom: 1rem;
}

/* Contact */
.contact-info {
    text-align: center;
    background: var(--secondary-dark);
    padding: 3rem;
    border-radius: 20px;
    margin-top: 2rem;
}

.contact-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
}

.contact-links a {
    color: var(--accent-blue);
    text-decoration: none;
    padding: 1rem 2rem;
    border: 2px solid var(--accent-blue);
    border-radius: 30px;
    transition: all 0.3s ease;
}

.contact-links a:hover {
    background: var(--accent-blue);
    color: white;
    transform: translateY(-3px);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Design */

/* Tablet Landscape - 768px to 991px */
@media (max-width: 991px) {
    nav {
        top: 18px;
        max-width: 70%;
    }

    .nav-container {
        height: 1rem;
    }
    
    .nav-links {
        gap: 0.15rem;
        padding-bottom: .35rem;
    }
    
    .nav-links a {
        padding: 0.2rem 0.4rem;
        font-size: 0.6rem;
    }
    
    .logo {
        top: 20px;
        left: 20px;
        font-size: 1.5rem;
    }
    
    .hero h1 {
        font-size: 3.5rem;
    }
    
    .hero .subtitle {
        font-size: 1.4rem;
    }
    
    .hero .description {
        font-size: 1rem;
        padding: 0 1rem;
    }
    
    .section {
        padding: 4rem 0;
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .section-title {
        font-size: 2.2rem;
        margin-bottom: 2.5rem;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1.5rem;
    }
    
    .cert-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 1.5rem;
    }
    
    .extra-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 1.5rem;
    }
    
    .contact-links {
        flex-wrap: wrap;
        gap: 1rem;
    }
    
    .contact-links a {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }
    
    .cta-buttons {
        flex-wrap: wrap;
        gap: 1rem;
    }
    
    .btn {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }
}

/* Tablet Portrait - 576px to 767px */
@media (max-width: 767px) {
    nav {
        top: 14px;
        max-width: 70%;
    }

    .nav-container {
        height: .8rem;
    }
    
    .nav-links {
        gap: 0.09rem;
        padding-bottom: .4rem;
    }
    
    .nav-links a {
        padding: 0.2rem 0.3rem;
        font-size: 0.45rem;
    }
    
    .logo {
        top: 16px;
        left: 15px;
        font-size: 1.4rem;
    }
    
    .hero {
        padding: 0 1rem;
    }
    
    .hero h1 {
        font-size: 2.8rem;
    }
    
    .hero .subtitle {
        font-size: 1.2rem;
    }
    
    .hero .description {
        font-size: 0.95rem;
        padding: 0 0.5rem;
    }
    
    .section {
        padding: 3rem 0;
        padding-left: 0.8rem;
        padding-right: 0.8rem;
    }
    
    .section-title {
        font-size: 2rem;
        margin-bottom: 2rem;
    }
    
    .education-item,
    .project-card,
    .skill-category,
    .cert-card,
    .achievement-card,
    .experience-card,
    .extra-card {
        padding: 1.5rem;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .cert-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .extra-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .contact-info {
        padding: 2rem 1rem;
    }
    
    .contact-links {
        flex-direction: column;
        gap: 1rem;
    }
    
    .contact-links a {
        padding: 0.8rem 1.2rem;
        font-size: 0.9rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        padding: 0.8rem 1.2rem;
        font-size: 0.9rem;
        width: 100%;
        max-width: 200px;
        text-align: center;
    }
}

/* Mobile Large - 480px to 575px */
@media (max-width: 575px) {
    nav {
        top: 10px;
        max-width: 70%;
    }

    .nav-container {
        height: .6rem;
    }
    
    .nav-links {
        gap: 0.08rem;
        padding-bottom: .45rem;
    }
    
    .nav-links a {
        padding: 0.2rem 0.3rem;
        font-size: 0.35rem;
    }
    
    .logo {
        top: 15px;
        left: 15px;
        font-size: 1.1rem;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero .subtitle {
        font-size: 1.1rem;
    }
    
    .hero .description {
        font-size: 0.9rem;
        padding: 0;
    }
    
    .section {
        padding: 2.5rem 0;
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }
    
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 1.5rem;
    }
    
    .education-item,
    .project-card,
    .skill-category,
    .cert-card,
    .achievement-card,
    .experience-card,
    .extra-card {
        padding: 1.2rem;
    }
    
    .skill-tags {
        gap: 0.3rem;
    }
    
    .skill-tag {
        padding: 0.4rem 0.8rem;
        font-size: 0.8rem;
    }
    
    .contact-info {
        padding: 1.5rem 0.8rem;
    }
    
    .contact-links a {
        padding: 0.7rem 1rem;
        font-size: 0.85rem;
    }
    
    .btn {
        padding: 0.7rem 1rem;
        font-size: 0.85rem;
        max-width: 180px;
    }
}

/* Mobile Medium - 400px to 479px */
@media (max-width: 479px) {
    nav {
        top: 10px;
        max-width: 70%;
    }

    .nav-container {
        height: 1px;
    }
    
    .nav-links {
        gap: 0.08rem;
        padding-bottom: 9px;
    }
    
    .nav-links a {
        padding: 0.1rem 0.18rem;
        font-size: 0.32rem;
    }
    
    .logo {
        top: 10px;
        left: 12px;
        font-size: 1rem;
    }
    
    .hero h1 {
        font-size: 2.2rem;
    }
    
    .hero .subtitle {
        font-size: 1rem;
    }
    
    .hero .description {
        font-size: 0.85rem;
        line-height: 1.6;
    }
    
    .section {
        padding: 2rem 0;
        padding-left: 0.3rem;
        padding-right: 0.3rem;
    }
    
    .section-title {
        font-size: 1.6rem;
        margin-bottom: 1.2rem;
    }
    
    .education-item,
    .project-card,
    .skill-category,
    .cert-card,
    .achievement-card,
    .experience-card,
    .extra-card {
        padding: 1rem;
    }
    
    .skill-tag {
        padding: 0.3rem 0.6rem;
        font-size: 0.75rem;
    }
    
    .contact-info {
        padding: 1.2rem 0.5rem;
    }
    
    .contact-links a {
        padding: 0.6rem 0.8rem;
        font-size: 0.8rem;
    }
    
    .btn {
        padding: 0.6rem 0.8rem;
        font-size: 0.8rem;
        max-width: 160px;
    }
}

/* Mobile Small - 380px to 399px */
@media (max-width: 399px) {
    nav {
        top: 12px;
        max-width: 62%;
    }

    .nav-container {
        height: 0px;
    }
    
    .nav-links {
        gap: 0.07rem;
        padding-bottom: .56rem;
    }
    
    .nav-links a {
        padding: 0rem 0.16rem;
        font-size: 0.26rem;
    }
    
    .logo {
        top: 14px;
        left: 10px;
        font-size: 0.9rem;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero .subtitle {
        font-size: 0.9rem;
    }
    
    .hero .description {
        font-size: 0.8rem;
        line-height: 1.5;
    }
    
    .section {
        padding: 1.5rem 0;
        padding-left: 0.2rem;
        padding-right: 0.2rem;
    }
    
    .section-title {
        font-size: 1.4rem;
        margin-bottom: 1rem;
    }
    
    .education-item,
    .project-card,
    .skill-category,
    .cert-card,
    .achievement-card,
    .experience-card,
    .extra-card {
        padding: 0.8rem;
    }
    
    .skill-tag {
        padding: 0.25rem 0.5rem;
        font-size: 0.7rem;
    }
    
    .contact-info {
        padding: 1rem 0.3rem;
    }
    
    .contact-links a {
        padding: 0.5rem 0.6rem;
        font-size: 0.75rem;
    }
    
    .btn {
        padding: 0.5rem 0.6rem;
        font-size: 0.75rem;
        max-width: 140px;
    }
}

/* Mobile Small - 320px to 379px */
@media (max-width: 379px) {
    nav {
        top: 10px;
        max-width: 70%;
    }

    .nav-container {
        height: 0px;
    }
    
    .nav-links {
        gap: 0.07rem;
        padding-bottom: .5rem;
    }
    
    .nav-links a {
        padding: 0rem 0.16rem;
        font-size: 0.25rem;
    }
    
    .logo {
        top: 12px;
        left: 10px;
        font-size: 0.9rem;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero .subtitle {
        font-size: 0.9rem;
    }
    
    .hero .description {
        font-size: 0.8rem;
        line-height: 1.5;
    }
    
    .section {
        padding: 1.5rem 0;
        padding-left: 0.2rem;
        padding-right: 0.2rem;
    }
    
    .section-title {
        font-size: 1.4rem;
        margin-bottom: 1rem;
    }
    
    .education-item,
    .project-card,
    .skill-category,
    .cert-card,
    .achievement-card,
    .experience-card,
    .extra-card {
        padding: 0.8rem;
    }
    
    .skill-tag {
        padding: 0.25rem 0.5rem;
        font-size: 0.7rem;
    }
    
    .contact-info {
        padding: 1rem 0.3rem;
    }
    
    .contact-links a {
        padding: 0.5rem 0.6rem;
        font-size: 0.75rem;
    }
    
    .btn {
        padding: 0.5rem 0.6rem;
        font-size: 0.75rem;
        max-width: 140px;
    }
}

/* Ultra Small Devices - 230px to 319px */
@media (max-width: 319px) {
    nav {
        top: 6px;
        max-width: 70%;
    }

    .nav-container {
        height: 0px;
    }
    
    .nav-links {
        gap: 0.07px;
        padding-bottom: .7rem;
    }
    
    .nav-links a {
        padding: 0rem 0.14rem;
        font-size: 3px;
    }
    
    .logo {
        top: 5.2px;
        left: 6px;
        font-size: 0.5rem;
    }
    
    .hero h1 {
        font-size: 1.8rem;
    }
    
    .hero .subtitle {
        font-size: 0.8rem;
    }
    
    .hero .description {
        font-size: 0.75rem;
        line-height: 1.4;
    }
    
    .section {
        padding: 1.2rem 0;
        padding-left: 0.1rem;
        padding-right: 0.1rem;
    }
    
    .section-title {
        font-size: 1.2rem;
        margin-bottom: 0.8rem;
    }
    
    .education-item,
    .project-card,
    .skill-category,
    .cert-card,
    .achievement-card,
    .experience-card,
    .extra-card {
        padding: 0.6rem;
    }
    
    .skill-tag {
        padding: 0.2rem 0.4rem;
        font-size: 0.65rem;
    }
    
    .contact-info {
        padding: 0.8rem 0.2rem;
    }
    
    .contact-links a {
        padding: 0.4rem 0.5rem;
        font-size: 0.7rem;
    }
    
    .btn {
        padding: 0.4rem 0.5rem;
        font-size: 0.7rem;
        max-width: 120px;
    }
}

/* Landscape Orientation Adjustments */
@media (orientation: landscape) and (max-height: 500px) {
    .hero {
        height: 100vh;
        padding: 1rem;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero .subtitle {
        font-size: 1rem;
    }
    
    .hero .description {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }
    
    .cta-buttons {
        gap: 0.5rem;
    }
    
    .btn {
        padding: 0.5rem 1rem;
        font-size: 0.8rem;
    }
}

/* High DPI Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .hero-video video {
        filter: blur(1px) brightness(0.6) contrast(0.9);
    }
}

/* Hover Effects Adjustments for Touch Devices */
@media (hover: none) and (pointer: coarse) {
    .project-card:hover,
    .skill-category:hover,
    .cert-card:hover,
    .achievement-card:hover,
    .experience-card:hover,
    .extra-card:hover,
    .education-item:hover {
        transform: none;
        box-shadow: none;
    }
    
    .nav-links a:hover {
        transform: none;
        box-shadow: none;
        border-bottom: none;
    }
    
    .btn:hover {
        transform: none;
        box-shadow: none;
    }
    
    .skill-tag:hover {
        transform: none;
        box-shadow: none;
    }
}

/* Print Styles */
@media print {
    nav,
    .hero-video,
    .cta-buttons {
        display: none;
    }
    
    .hero {
        height: auto;
        background: white;
        color: black;
        padding: 2rem;
    }
    
    .section {
        padding: 1rem 0;
        break-inside: avoid;
    }
    
    .project-card,
    .cert-card,
    .achievement-card,
    .experience-card,
    .extra-card,
    .education-item {
        break-inside: avoid;
        border: 1px solid #ccc;
        background: white;
        color: black;
    }
}