:root {
    --primary-color: #004f90;
    --secondary-color: #00c6ff;
    --text-color: #ffffff;
    --bg-color: #0f172a;
    --glass-bg: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.2);
    --card-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    overflow-x: hidden;
}

/* Background Gradient Animation */
.background-gradient {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(45deg, #0f172a, #1e293b, #004f90);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1.5rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid var(--glass-border);
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(to right, #fff, var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--secondary-color);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5%;
    padding-top: 80px;
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1200px;
    gap: 2rem;
}

.hero-text {
    flex: 1;
}

.hero-text h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.highlight {
    color: var(--secondary-color);
}

.hero-text h2 {
    font-size: 2rem;
    color: #94a3b8;
    margin-bottom: 1.5rem;
}

.hero-text p {
    font-size: 1.1rem;
    color: #cbd5e1;
    margin-bottom: 2rem;
    max-width: 600px;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

/* Resume Button Hover Animation */
.resume-btn {
    position: relative;
    overflow: hidden;
    background: linear-gradient(90deg, #0ea5e9, #0284c7);
    transition: background 0.3s ease;
}

.resume-btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #0284c7, #0c4a6e);
    transition: all 0.4s ease;
    z-index: 0;
}

.resume-btn:hover::before {
    left: 0;
}

.resume-btn:hover {
    color: #fff !important;
}

.resume-btn span,
.resume-btn {
    position: relative;
    z-index: 1;
}


.btn {
    padding: 0.8rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn.primary {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    box-shadow: 0 4px 15px rgba(0, 198, 255, 0.3);
}

.btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 198, 255, 0.5);
}

.btn.secondary {
    background: transparent;
    border: 2px solid var(--secondary-color);
    color: var(--secondary-color);
}

.btn.secondary:hover {
    background: rgba(0, 198, 255, 0.1);
}

.social-links {
    display: flex;
    gap: 1.5rem;
}

.social-links a {
    color: #cbd5e1;
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

.social-links a:hover {
    color: var(--secondary-color);
    transform: translateY(-3px);
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
}

.img-container {
    width: 350px;
    height: 350px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--secondary-color);
    box-shadow: 0 0 30px rgba(0, 198, 255, 0.3);
    position: relative;
}

.img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Glassmorphism Cards */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: var(--card-shadow);
    transition: transform 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.4);
}

/* Sections */
.section {
    padding: 5rem 5%;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
    background: linear-gradient(to right, #fff, var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Add slight vertical spacing for About Me card */
#about .about-content {
    margin-top: 1.2rem;   /* space below the title */
    margin-bottom: 1.2rem; /* optional bottom spacing */
}


/* Skills Grid */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.skill-category h3 {
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--secondary-color);
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.tags span {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.tags span:hover {
    background: var(--secondary-color);
    color: #000;
}

/* Projects Grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.project-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1rem;
}

.project-link {
    color: var(--text-color);
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.project-link:hover {
    color: var(--secondary-color);
}

.project-card p {
    color: #cbd5e1;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

/* Timeline */
.timeline {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.timeline-item {
    position: relative;
    padding-left: 2rem;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--secondary-color);
    border-radius: 2px;
}

.date {
    display: inline-block;
    background: var(--secondary-color);
    color: #000;
    padding: 0.2rem 0.8rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.timeline-item h3 {
    margin-bottom: 0.2rem;
}

.timeline-item h4 {
    color: #94a3b8;
    margin-bottom: 1rem;
}

.timeline-item ul {
    list-style-position: inside;
    color: #cbd5e1;
}

.timeline-item ul li {
    margin-bottom: 0.5rem;
}

/* Improved spacing for form */
.contact-form {
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 2rem; /* Increased spacing between groups */
}

/* Two-column row spacing */
.form-row.two {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem; /* Increase column spacing */
}

/* Spacing for each input block */
.field {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;  /* Gap between label, input, and hint */
    margin-bottom: 1rem; /* Extra space below each field */
}

/* Inputs spacing upgrade */
.field input,
.field textarea {
    padding: 1.1rem 1rem;
    border-radius: 14px;
    font-size: 1rem;
}

/* Proper spacing for hints */
.hint {
    margin-top: -4px;
    opacity: 0.85;
}

/* Fix floating badge spacing */
.badge {
    top: -14px;
    padding: 0.3rem 0.75rem;
    font-size: 0.85rem;
}

/* Checkbox spacing */
.agree {
    margin: 1rem 0 1.5rem;
}

/* Extra spacing above send button */
.btn.glow {
    margin-top: 0.5rem;
}

/* Textarea height + spacing fix */
#message {
    min-height: 160px;
}

/* --- Compact Get In Touch Section --- */

/* Make the contact form narrower (75% width) */
#contact .contact-form {
    max-width: 75%;
    margin: 0 auto; /* center it */
    padding: 1.8rem; /* reduced padding */
    gap: 1.4rem; /* reduce spacing between fields */
}

/* Compact the 2-column spacing */
#contact .form-row.two {
    gap: 1.5rem;
}

/* Reduce vertical spacing between each field */
#contact .field {
    gap: 0.5rem;
    margin-bottom: 0.6rem;
}

/* Reduce input padding for a tighter look */
#contact .field input,
#contact .field textarea {
    padding: 0.9rem 1rem;
}

/* Adjust badge label spacing */
#contact .badge {
    top: -12px;
}

/* Reduce checkbox margin */
#contact .agree {
    margin: 0.6rem 0 1rem;
}

/* Reduce space above button */
#contact .btn.glow {
    margin-top: 0.3rem;
}

/* Smaller short form textarea */
#contact #message {
    min-height: 130px;
}

/* Responsive: Full width on mobile */
@media (max-width: 768px) {
    #contact .contact-form {
        max-width: 100%;
    }
}

/* Contact */
.contact-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.contact-info {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-color);
    text-decoration: none;
    padding: 0.8rem 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50px;
    transition: all 0.3s ease;
}

.contact-item:hover {
    background: var(--secondary-color);
    color: #000;
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem;
    color: #94a3b8;
    background: rgba(15, 23, 42, 0.9);
}

/* Responsive */
@media (max-width: 768px) {
    .hero-content {
        flex-direction: column-reverse;
        text-align: center;
    }

    .hero-text h1 {
        font-size: 2.5rem;
    }

    .hero-buttons {
        justify-content: center;
    }

    .social-links {
        justify-content: center;
    }

    .nav-links {
        display: none;
    }
    
    .hamburger {
        display: block;
        cursor: pointer;
    }
    
    .hamburger .bar {
        display: block;
        width: 25px;
        height: 3px;
        margin: 5px auto;
        background-color: white;
    }
}

/* ===== Advanced Resume Button ===== */
.resume-btn{
  position: relative;
  overflow: hidden;
  border: none;
  color: #fff;
  /* animated base gradient (idle) */
  background: linear-gradient(90deg,
      var(--primary-color) 0%,
      var(--secondary-color) 50%,
      #34d3ff 100%);
  background-size: 200% 100%;
  animation: resumeGradientIdle 6s ease-in-out infinite;
  border-radius: 16px;               /* slightly squarer than pills */
  padding: 0.9rem 2rem;              /* a touch larger */
  box-shadow: 0 8px 24px rgba(0,198,255,.25);
  transition: transform .5s ease, box-shadow .5s ease, filter .25s ease;
  isolation: isolate;                /* keep pseudo-elements under text */
}

/* Deep-blue sweep layer (hover) */
.resume-btn::before{
  content:"";
  position:absolute; inset:0;
  background: linear-gradient(90deg,
      #02223f 0%,
      #024d8a 40%,
      #007ed6 70%,
      #00a8ff 100%);
  transform: translateX(-100%);      /* start off-screen left */
  transition: transform .45s cubic-bezier(.2,.7,.2,1);
  z-index: 0;
}

/* Glossy shine pass */
.resume-btn::after{
  content:"";
  position:absolute; inset:-20%;
  background: linear-gradient(110deg,
      rgba(255,255,255,0) 20%,
      rgba(255,255,255,.35) 35%,
      rgba(255,255,255,0) 50%);
  transform: translateX(-120%) rotate(3deg);
  transition: transform .7s ease;
  mix-blend-mode: screen;
  filter: blur(1px);
  z-index: 0;
}

/* Text sits above effects */
.resume-btn span{ position: relative; z-index: 1; }

/* Hover: sweep in, shine slides across, deepen glow */
.resume-btn:hover{
  box-shadow: 0 10px 32px rgba(0,198,255,.40);
  filter: saturate(1.1);
}
.resume-btn:hover::before{ transform: translateX(0); }
.resume-btn:hover::after{  transform: translateX(120%) rotate(3deg); }

/* Active click: subtle press */
.resume-btn:active{ transform: translateY(1px) scale(.99); }

/* Keyboard focus – accessible outline */
.resume-btn:focus-visible{
  outline: 3px solid rgba(0,198,255,.55);
  outline-offset: 3px;
}

/* Idle gradient drift */
@keyframes resumeGradientIdle{
  0%   { background-position: 0% 50%;   }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%;   }
}

/* Respect users who prefer reduced motion */
@media (prefers-reduced-motion: reduce){
  .resume-btn{ animation: none; }
  .resume-btn::after{ display: none; }
}
