:root{
  --bg:#070b18;
  --bg2:#0b1230;
  --card:#0f1b3a;
  --card2:#0b1634;

  --text:#e7eefc;
  --muted:#a7b7da;

  --accent:#38bdf8;         /* cyan */
  --accent-soft: rgba(56,189,248,.18);
  --border: rgba(56,189,248,.18);
  --shadow: rgba(0,0,0,.45);
}

*{
  margin:0;
  padding:0;
  box-sizing:border-box;
  font-family: Inter, Arial, sans-serif;
}

html{
  scroll-behavior:smooth;
}

body{
  color: var(--text);
  background:
    radial-gradient(1200px 700px at 20% 10%, rgba(56,189,248,.18), transparent 55%),
    radial-gradient(900px 600px at 85% 20%, rgba(56,189,248,.10), transparent 55%),
    linear-gradient(180deg, var(--bg), var(--bg2));
}

/* HEADER */
.site-header{
  position: sticky;
  top: 0;
  z-index: 10;
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding: 18px 60px;
  background: rgba(2,6,23,.65);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(56,189,248,.15);
}

.logo{
  font-family: Orbitron, sans-serif;
  font-size: 22px;
  letter-spacing: .6px;
}

.nav a{
  color: var(--muted);
  text-decoration:none;
  margin-left: 22px;
  position: relative;
  padding-bottom: 8px;
  transition: .2s ease;
}

.nav a:hover{
  color: var(--text);
}

.nav a::after{
  content:"";
  position:absolute;
  left:0;
  bottom:0;
  width:0%;
  height:2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  box-shadow: 0 0 12px rgba(56,189,248,.65);
  transition: .25s ease;
}

.nav a:hover::after{
  width:100%;
}

/* SECTIONS */
.section{
  padding: 90px 60px;
  text-align:center;
}

.section-title{
  font-family: Orbitron, sans-serif;
  letter-spacing: .8px;
  margin-bottom: 18px;
  display: inline-block;
  padding-bottom: 10px;
  border-bottom: 2px solid rgba(56,189,248,.25);
  text-shadow: 0 0 16px rgba(56,189,248,.20);
}

.section-text{
  max-width: 900px;
  margin: 0 auto;
  color: var(--muted);
  line-height: 1.8;
}

/* HERO */
.home{
  min-height: 82vh;
  display:flex;
  justify-content:center;
  align-items:center;
  text-align:center;
  position: relative;
  overflow:hidden;
  padding: 90px 60px;
  border-bottom: 1px solid rgba(56,189,248,.12);
}

/* cyber grid background */
.home::before{
  content:"";
  position:absolute;
  inset:0;
  background:
    radial-gradient(circle at 20% 40%, rgba(56,189,248,.18), transparent 45%),
    radial-gradient(circle at 70% 30%, rgba(56,189,248,.12), transparent 45%),
    repeating-linear-gradient(90deg, rgba(56,189,248,.06) 0, rgba(56,189,248,.06) 1px, transparent 1px, transparent 70px),
    repeating-linear-gradient(0deg, rgba(56,189,248,.04) 0, rgba(56,189,248,.04) 1px, transparent 1px, transparent 70px);
  opacity: .9;
  pointer-events:none;
}

.home::after{
  content:"";
  position:absolute;
  inset:0;
  background: linear-gradient(180deg, rgba(2,6,23,.10), rgba(2,6,23,.88));
  pointer-events:none;
}

.hero{
  position: relative;
  z-index: 1;
  max-width: 1000px;
}

.hero-kicker{
  color: var(--muted);
  font-size: 18px;
  margin-bottom: 6px;
}

.hero-title{
  font-family: Orbitron, sans-serif;
  font-size: 52px;
  letter-spacing: .6px;
  text-shadow: 0 0 26px rgba(56,189,248,.25);
  margin-bottom: 12px;
}

.hero-subtitle{
  color: var(--muted);
  line-height: 1.7;
  max-width: 900px;
  margin: 0 auto;
}

/* Buttons */
.hero-actions{
  margin-top: 18px;
  display:flex;
  gap: 12px;
  justify-content:center;
  flex-wrap: wrap;
}

.btn{
  display:inline-block;
  padding: 12px 22px;
  border-radius: 12px;
  border: 1px solid rgba(56,189,248,.55);
  background: rgba(56,189,248,.10);
  color: var(--text);
  text-decoration:none;
  cursor:pointer;
  font-weight: 600;
  letter-spacing: .3px;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
  box-shadow: 0 0 18px rgba(56,189,248,.18);
}

.btn:hover{
  transform: translateY(-2px);
  background: rgba(56,189,248,.16);
  box-shadow: 0 0 28px rgba(56,189,248,.32);
}

.btn-ghost{
  background: rgba(15,27,58,.35);
  border: 1px solid rgba(56,189,248,.25);
  box-shadow: none;
}

.btn-ghost:hover{
  background: rgba(15,27,58,.55);
  box-shadow: 0 0 22px rgba(56,189,248,.18);
}

/* SKILLS pills */
.pill-wrap{
  margin-top: 18px;
  display:flex;
  justify-content:center;
  flex-wrap: wrap;
  gap: 12px;
}

/* ✅ UPGRADED GLOW (skills) */
.pill{
  display:inline-block;
  padding: 10px 16px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(15,27,58,.90), rgba(11,22,52,.90));
  border: 1px solid rgba(56,189,248,.35);
  color: var(--text);

  /* stronger neon glow */
  box-shadow:
    0 0 12px rgba(56,189,248,.35),
    0 0 26px rgba(56,189,248,.18);

  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.pill:hover{
  transform: translateY(-2px);

  border-color: rgba(56,189,248,.9);

  box-shadow:
    0 0 18px rgba(56,189,248,.65),
    0 0 44px rgba(56,189,248,.35);
}

/* PROJECTS cards */
.card-grid{
  margin-top: 18px;
  display:flex;
  justify-content:center;
  gap: 20px;
  flex-wrap: wrap;
}

/* ✅ UPGRADED GLOW (projects) */
.card{
  width: 320px;
  padding: 26px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(15,27,58,.92), rgba(11,22,52,.92));
  border: 1px solid rgba(56,189,248,.30);

  /* add a subtle always-on neon halo */
  box-shadow:
    0 14px 50px rgba(0,0,0,.35),
    0 0 18px rgba(56,189,248,.16);

  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
  text-align:left;
}

.card:hover{
  transform: translateY(-8px);

  border-color: rgba(56,189,248,.9);

  box-shadow:
    0 18px 65px rgba(0,0,0,.45),
    0 0 36px rgba(56,189,248,.30),
    0 0 70px rgba(56,189,248,.18);
}

.card-icon{
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display:flex;
  align-items:center;
  justify-content:center;
  margin-bottom: 14px;
  background: rgba(56,189,248,.12);
  border: 1px solid rgba(56,189,248,.25);
}

.card-title{
  font-size: 18px;
  margin-bottom: 8px;
}

.card-text{
  color: var(--muted);
  line-height: 1.7;
}

/* CONTACT */
.contact-card{
  max-width: 700px;
  margin: 18px auto 0;
  padding: 22px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(15,27,58,.85), rgba(11,22,52,.85));
  border: 1px solid rgba(56,189,248,.18);
  color: var(--text);
  text-align:left;
  box-shadow: 0 14px 50px rgba(0,0,0,.35);
}

.contact-card p{
  margin: 10px 0;
  color: var(--muted);
}

.contact-card strong{
  color: var(--text);
}

.contact-note{
  font-size: 13px;
  opacity: .9;
}

/* FOOTER */
.footer{
  background: rgba(2,6,23,.7);
  border-top: 1px solid rgba(56,189,248,.12);
  color: var(--muted);
  text-align:center;
  padding: 18px;
}

/* RESPONSIVE */
@media (max-width: 900px){
  .site-header{
    padding: 16px 18px;
    flex-direction: column;
    gap: 10px;
  }
  .nav a{
    margin: 0 10px;
  }
  .home, .section{
    padding: 70px 18px;
  }
  .hero-title{
    font-size: 36px;
  }
  .card{
    width: 100%;
    max-width: 420px;
  }
}

/* =========================================================
   ✅ ADDED: HOME PHOTO (top-right, smaller, head not cut)
   ========================================================= */

.hero-wrap{
  position: relative;
  z-index: 1;
  width: min(1100px, 100%);
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap: 40px;
}

.hero-wrap .hero{
  text-align: left;
  max-width: 650px;
}

.hero-photo{
  width: 210px;
  height: 210px;
  border-radius: 18px;
  padding: 6px;
  flex: 0 0 auto;

  margin-top: -55px;

  background: linear-gradient(135deg,
    rgba(56,189,248,1),
    rgba(56,189,248,.28),
    rgba(56,189,248,1)
  );

  box-shadow:
    0 0 26px rgba(56,189,248,.65),
    0 0 85px rgba(56,189,248,.22);
}

.hero-photo img{
  width: 100%;
  height: 100%;
  border-radius: 14px;

  object-fit: cover;
  object-position: center top;

  display:block;
  border: 1px solid rgba(56,189,248,.22);
}

.hero-photo:hover{
  box-shadow:
    0 0 34px rgba(56,189,248,.80),
    0 0 105px rgba(56,189,248,.30);
}

@media (max-width: 900px){
  .hero-wrap{
    flex-direction: column;
    align-items: center;
    gap: 22px;
  }

  .hero-wrap .hero{
    text-align: center;
  }

  .hero-photo{
    margin-top: 0;
  }
}

/* =========================================================
   ✅ ADDED: CLICK-TO-OPEN DETAILS (project cards)
   ========================================================= */

.card-details{
  padding: 0; /* summary handles padding */
}

.card-details .card-summary{
  list-style: none;
  cursor: pointer;
  padding: 26px;
  user-select: none;
}

.card-details summary::-webkit-details-marker{
  display:none;
}

.card-hint{
  display: inline-block;
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
  opacity: .9;
}

.card-more{
  padding: 0 26px 22px 26px;
  border-top: 1px solid rgba(56,189,248,.18);
}

.card-list{
  margin: 10px 0 12px 18px;
  color: var(--muted);
  line-height: 1.7;
}

.card-list li{
  margin: 6px 0;
}

/* glow when opened */
.card-details[open]{
  border-color: rgba(56,189,248,.9);
  box-shadow:
    0 18px 65px rgba(0,0,0,.45),
    0 0 36px rgba(56,189,248,.30),
    0 0 70px rgba(56,189,248,.18);
}

/* =========================================================
   ✅ Projects: equal size -> open expands -> others shrink equally
   Only affects #projects
   ========================================================= */

#projects .card-grid{
  display: flex;
  flex-wrap: nowrap;
  gap: 20px;
  align-items: flex-start;
}

/* INITIAL: all cards exactly equal width */
#projects .card-grid > .card{
  width: 0;            /* ignore content width */
  min-width: 0;        /* allow shrinking */
  flex: 1 1 0;         /* equal share */
  transition: flex .25s ease, transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

/* WHEN any is open: shrink all cards equally */
#projects .card-grid:has(details[open]) > .card{
  flex: 0.75 1 0;
}

/* Expand ONLY the open one */
#projects .card-grid > .card:has(details[open]),
#projects .card-grid > details.card[open]{
  flex: 2.3 1 0;
}

/* ✅ NEW: Make CARD 3 expand to the LEFT (anchor right edge)
   This targets the 3rd project card when it's a <details> and open */
#projects .card-grid > details.card-details:nth-child(3)[open]{
  transform-origin: right center;
}

/* Mobile: allow wrapping */
@media (max-width: 900px){
  #projects .card-grid{
    flex-wrap: wrap;
  }
  #projects .card-grid > .card{
    width: 100%;
    flex: 1 1 100%;
    min-width: 0;
  }
}
/* =========================
   LinkedIn QR Professional Layout
   ========================= */

.linkedin-card{
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.linkedin-content{
  flex: 1;
}

.linkedin-qr{
  flex-shrink: 0;
}

.linkedin-qr img{
  width: 105px;
  height: auto;
  border-radius: 10px;
  border: 1px solid rgba(56,189,248,.35);
  box-shadow: 0 0 15px rgba(56,189,248,.25);
  transition: transform .2s ease, box-shadow .2s ease;
}

.linkedin-qr img:hover{
  transform: scale(1.05);
  box-shadow: 0 0 25px rgba(56,189,248,.45);
}

@media (max-width: 600px){
  .linkedin-card{
    flex-direction: column;
    text-align: center;
  }

  .linkedin-qr img{
    margin-top: 15px;
  }
}

