/**
* Ali Mobarekati Portfolio — modern visual system
* Based on MyResume template structure; fully restyled.
*/

/*--------------------------------------------------------------
# Design tokens
--------------------------------------------------------------*/
:root {
  --primary: #3b82f6;
  --primary-hover: #2563eb;
  --primary-soft: rgba(59, 130, 246, 0.12);
  --primary-glow: rgba(59, 130, 246, 0.35);
  --accent: #06b6d4;
  --text: #0f172a;
  --text-muted: #64748b;
  --text-soft: #94a3b8;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --surface-3: #f1f5f9;
  --border: rgba(15, 23, 42, 0.08);
  --border-strong: rgba(15, 23, 42, 0.12);
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 8px 30px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 50px rgba(15, 23, 42, 0.12);
  --shadow-glow: 0 12px 40px rgba(59, 130, 246, 0.22);
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 999px;
  --font-sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Outfit", "Inter", system-ui, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --nav-width: 100px;
  --header-bg-mobile: rgba(255, 255, 255, 0.92);
}

/*--------------------------------------------------------------
# Base
--------------------------------------------------------------*/
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--surface-2);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background: rgba(59, 130, 246, 0.2);
  color: var(--text);
}

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

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

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text);
  line-height: 1.25;
}

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

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-track {
  background: var(--surface-3);
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: var(--radius-full);
  border: 2px solid var(--surface-3);
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/*--------------------------------------------------------------
# Back to top
--------------------------------------------------------------*/
.back-to-top {
  position: fixed;
  visibility: hidden;
  opacity: 0;
  right: 20px;
  bottom: 20px;
  z-index: 996;
  background: linear-gradient(135deg, var(--primary), #6366f1);
  width: 46px;
  height: 46px;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-glow);
  transition: all 0.35s var(--ease);
  display: flex;
  align-items: center;
  justify-content: center;
}
.back-to-top i {
  font-size: 22px;
  color: #fff;
  line-height: 0;
}
.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 40px rgba(59, 130, 246, 0.4);
  color: #fff;
}
.back-to-top.active {
  visibility: visible;
  opacity: 1;
}

/*--------------------------------------------------------------
# Preloader
--------------------------------------------------------------*/
#preloader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  overflow: hidden;
  background: var(--surface-2);
}

#preloader:before {
  content: "";
  position: fixed;
  top: calc(50% - 28px);
  left: calc(50% - 28px);
  border: 3px solid transparent;
  border-top-color: var(--primary);
  border-right-color: var(--accent);
  border-radius: 50%;
  width: 56px;
  height: 56px;
  animation: animate-preloader 0.85s linear infinite;
}

@keyframes animate-preloader {
  to { transform: rotate(360deg); }
}

/*--------------------------------------------------------------
# Disable aos delay on mobile
--------------------------------------------------------------*/
@media screen and (max-width: 768px) {
  [data-aos-delay] {
    transition-delay: 0 !important;
  }
}

/*--------------------------------------------------------------
# Header / Nav
--------------------------------------------------------------*/
#header {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 9997;
  transition: all 0.45s var(--ease);
  padding: 20px 15px;
  overflow-y: auto;
}

@media (max-width: 992px) {
  #header {
    width: 280px;
    background: var(--header-bg-mobile);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-right: 1px solid var(--border);
    left: -280px;
    box-shadow: var(--shadow-lg);
  }
}

@media (min-width: 992px) {
  #main {
    margin-left: var(--nav-width);
  }
}

.nav-menu {
  padding: 0;
  display: block;
}
.nav-menu * {
  margin: 0;
  padding: 0;
  list-style: none;
}
.nav-menu > ul > li {
  position: relative;
  white-space: nowrap;
}
.nav-menu a,
.nav-menu a:focus {
  display: flex;
  align-items: center;
  color: var(--text-muted);
  padding: 10px 18px;
  margin-bottom: 10px;
  font-size: 14px;
  font-weight: 500;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  height: 54px;
  width: 100%;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: all 0.35s var(--ease);
}
.nav-menu a i,
.nav-menu a:focus i {
  font-size: 20px;
  flex-shrink: 0;
}
.nav-menu a span,
.nav-menu a:focus span {
  padding: 0 6px 0 10px;
  color: var(--text-muted);
}

@media (min-width: 992px) {
  .nav-menu a,
  .nav-menu a:focus {
    width: 54px;
  }
  .nav-menu a span,
  .nav-menu a:focus span {
    display: none;
    color: #fff;
  }
}

.nav-menu a:hover,
.nav-menu .active,
.nav-menu .active:focus,
.nav-menu li:hover > a {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), #6366f1);
  border-color: transparent;
  box-shadow: var(--shadow-glow);
}
.nav-menu a:hover span,
.nav-menu .active span,
.nav-menu .active:focus span,
.nav-menu li:hover > a span {
  color: #fff;
}
.nav-menu a:hover,
.nav-menu li:hover > a {
  width: 100%;
  color: #fff;
}
.nav-menu a:hover span,
.nav-menu li:hover > a span {
  display: block;
}

/* Mobile nav toggle */
.mobile-nav-toggle {
  position: fixed;
  right: 14px;
  top: 14px;
  z-index: 9998;
  border: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  font-size: 24px;
  transition: all 0.35s var(--ease);
  outline: none !important;
  line-height: 0;
  cursor: pointer;
  border-radius: var(--radius-full);
  padding: 10px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
  color: var(--text);
}
.mobile-nav-toggle i {
  color: var(--text);
}

.mobile-nav-active {
  overflow: hidden;
}
.mobile-nav-active #header {
  left: 0;
}
.mobile-nav-active .mobile-nav-toggle {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), #6366f1);
  border-color: transparent;
}

/*--------------------------------------------------------------
# Hero
--------------------------------------------------------------*/
#hero {
  width: 100%;
  min-height: 100vh;
  background: url("../img/b1.jpg") center right no-repeat;
  background-size: cover;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  isolation: isolate;
}

@media (min-width: 992px) {
  #hero {
    padding-left: 160px;
  }
}

#hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(120deg, rgba(15, 23, 42, 0.88) 0%, rgba(15, 23, 42, 0.55) 48%, rgba(15, 23, 42, 0.35) 100%),
    radial-gradient(ellipse 80% 60% at 20% 50%, rgba(59, 130, 246, 0.25), transparent 55%);
}

#hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 60% at 30% 50%, black, transparent);
  pointer-events: none;
  opacity: 0.6;
}

#hero .container {
  position: relative;
  z-index: 1;
}

#hero .hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  margin-bottom: 22px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #e2e8f0;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-full);
  backdrop-filter: blur(8px);
}

#hero .hero-badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.25);
  animation: pulse-dot 2s ease infinite;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.25); }
  50% { box-shadow: 0 0 0 6px rgba(34, 197, 94, 0.1); }
}

#hero h1 {
  margin: 0;
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: #fff;
  text-shadow: 0 2px 30px rgba(0, 0, 0, 0.25);
}

#hero p {
  color: #cbd5e1;
  margin: 18px 0 0;
  font-size: clamp(1.05rem, 2.2vw, 1.45rem);
  font-family: var(--font-sans);
  font-weight: 400;
}

#hero p span {
  color: #93c5fd;
  font-weight: 600;
  letter-spacing: 0.01em;
  background: linear-gradient(90deg, #93c5fd, #67e8f9);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

#hero .social-links {
  margin-top: 36px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

#hero .social-links a {
  font-size: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  color: #e2e8f0;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
  line-height: 1;
  transition: all 0.3s var(--ease);
}

#hero .social-links a .hf-icon {
  font-size: 20px;
  line-height: 1;
}

#hero .social-links a:hover {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), #6366f1);
  border-color: transparent;
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

#hero .hero-scroll {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  animation: float-scroll 2.4s ease-in-out infinite;
  transition: opacity 0.35s var(--ease);
}

#hero .hero-scroll i {
  font-size: 18px;
}

@keyframes float-scroll {
  0%, 100% { transform: translateX(-50%) translateY(0); opacity: 0.55; }
  50% { transform: translateX(-50%) translateY(6px); opacity: 1; }
}

@media (min-width: 992px) {
  #hero .hero-scroll {
    left: calc(50% + 50px);
  }
}

@media (max-width: 992px) {
  #hero {
    text-align: center;
    padding: 100px 0 80px;
  }
  #hero .social-links {
    justify-content: center;
  }
  #hero .hero-badge {
    margin-left: auto;
    margin-right: auto;
  }
}

/*--------------------------------------------------------------
# Sections
--------------------------------------------------------------*/
section {
  padding: 90px 0;
  overflow: hidden;
  position: relative;
}

.section-bg,
#portfolio.section-bg {
  background: var(--surface);
}

#about {
  background: var(--surface-2);
}

#resume {
  background: var(--surface);
}

.section-title2 {
  padding-bottom: 36px;
}

.section-title2 h2 {
  padding-left: 4%;
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 700;
  text-transform: none;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
  padding-bottom: 16px;
  position: relative;
  color: var(--text);
}

.section-title2 h2::after {
  content: "";
  position: absolute;
  display: block;
  width: 56px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  bottom: 0;
  left: 4%;
  border-radius: var(--radius-full);
}

.section-title2 p {
  text-align: left;
  margin-bottom: 0;
  color: var(--text-muted);
  font-size: 1.05rem;
  max-width: 640px;
  line-height: 1.7;
}

.section-title {
  text-align: center;
  padding-bottom: 36px;
}
.section-title h2 {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 700;
  text-transform: none;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
  padding-bottom: 16px;
  position: relative;
  color: var(--text);
}
.section-title h2::before {
  display: none;
}
.section-title h2::after {
  content: "";
  position: absolute;
  display: block;
  width: 56px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  border-radius: var(--radius-full);
}
.section-title p {
  text-align: center;
  margin-bottom: 0;
  color: var(--text-muted);
}

.p-good_leftright {
  padding-left: 4%;
  padding-right: 4%;
}

/*--------------------------------------------------------------
# About
--------------------------------------------------------------*/
.about .content h3 {
  font-weight: 700;
  font-size: 26px;
  color: var(--text-muted);
}

.about .content ul {
  list-style: none;
  padding: 0;
  margin-bottom: 1.25rem;
}

.about .content ul li {
  margin-bottom: 12px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 12px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  font-size: 0.95rem;
  color: var(--text-muted);
}

.about .content ul strong {
  margin-right: 6px;
  color: var(--text);
}

.about .content ul i {
  font-size: 14px;
  margin-right: 2px;
  margin-top: 4px;
  color: var(--primary);
  line-height: 0;
  flex-shrink: 0;
}

.about .content p {
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.75;
  margin-bottom: 1rem;
}

.about .content p:last-child {
  margin-bottom: 0;
}

.about .about-photo {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}

.about .about-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.4);
  pointer-events: none;
}

.about .about-photo img {
  display: block;
  width: 100%;
  transition: transform 0.6s var(--ease);
}

.about .about-photo:hover img {
  transform: scale(1.03);
}

/* Skill chips */
.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.skill-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0.9rem;
  font-size: 0.8rem;
  font-weight: 500;
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-full);
  line-height: 1.35;
  box-shadow: var(--shadow-sm);
  transition: all 0.25s var(--ease);
  cursor: default;
}

.skill-chip:hover {
  color: var(--primary-hover);
  border-color: rgba(59, 130, 246, 0.35);
  background: var(--primary-soft);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(59, 130, 246, 0.12);
}

/* Legacy skills bars */
.skills .progress {
  height: 60px;
  display: block;
  background: none;
  border-radius: 0;
}
.skills .progress .skill {
  padding: 10px 0;
  margin: 0;
  text-transform: uppercase;
  display: block;
  font-weight: 600;
  font-family: var(--font-sans);
  color: var(--text-muted);
}
.skills .progress .skill .val {
  float: right;
  font-style: normal;
}
.skills .progress-bar-wrap {
  background: var(--surface-3);
  border-radius: var(--radius-full);
  overflow: hidden;
}
.skills .progress-bar {
  width: 1px;
  height: 8px;
  transition: 0.9s;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: var(--radius-full);
}

/*--------------------------------------------------------------
# Facts
--------------------------------------------------------------*/
.facts .count-box {
  padding: 36px 28px 28px;
  margin-top: 30px;
  width: 100%;
  position: relative;
  text-align: center;
  background: var(--surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
}
.facts .count-box i {
  position: absolute;
  top: -24px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 22px;
  background: linear-gradient(135deg, var(--primary), #6366f1);
  color: #fff;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  box-shadow: var(--shadow-glow);
}
.facts .count-box span {
  font-size: 36px;
  display: block;
  font-weight: 700;
  font-family: var(--font-display);
  color: var(--text);
}
.facts .count-box p {
  padding: 0;
  margin: 0;
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--text-muted);
}

/*--------------------------------------------------------------
# Resume
--------------------------------------------------------------*/
.resume .resume-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-top: 28px;
  margin-bottom: 18px;
  color: var(--text);
  letter-spacing: -0.02em;
}

.resume .resume-item {
  padding: 0 0 24px 24px;
  margin-top: -2px;
  border-left: 2px solid rgba(59, 130, 246, 0.25);
  position: relative;
}

.resume .resume-item h4 {
  line-height: 1.35;
  font-size: 1rem;
  font-weight: 600;
  text-transform: none;
  font-family: var(--font-display);
  color: var(--primary);
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.resume .resume-item h5 {
  font-size: 0.8rem;
  background: var(--primary-soft);
  color: var(--primary-hover);
  padding: 4px 12px;
  display: inline-block;
  font-weight: 600;
  margin-bottom: 10px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(59, 130, 246, 0.15);
}

.resume .resume-item p,
.resume .resume-item em {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.resume .resume-item ul {
  padding-left: 18px;
  color: var(--text-muted);
}

.resume .resume-item ul li {
  padding-bottom: 8px;
  font-size: 0.95rem;
}

.resume .resume-item:last-child {
  padding-bottom: 0;
}

.resume .resume-item::before {
  content: "";
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  left: -8px;
  top: 2px;
  background: var(--surface);
  border: 3px solid var(--primary);
  box-shadow: 0 0 0 3px var(--primary-soft);
}

/*--------------------------------------------------------------
# Portfolio
--------------------------------------------------------------*/
.portfolio .portfolio-item {
  margin-bottom: 24px;
}

.portfolio #portfolio-flters {
  padding: 6px;
  list-style: none;
  background: var(--surface-3);
  border-radius: var(--radius-full);
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 0 0 8px 4%;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.portfolio #portfolio-flters li {
  cursor: pointer;
  display: inline-block;
  padding: 10px 18px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  text-transform: none;
  color: var(--text-muted);
  margin-bottom: 0;
  border-radius: var(--radius-full);
  transition: all 0.3s var(--ease);
}

.portfolio #portfolio-flters li:hover,
.portfolio #portfolio-flters li.filter-active {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), #6366f1);
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.3);
}

.portfolio #portfolio-flters li:last-child {
  margin-right: 0;
}

.portfolio .portfolio-wrap {
  transition: all 0.4s var(--ease);
  position: relative;
  overflow: hidden;
  z-index: 1;
  background: transparent;
  border-radius: var(--radius-md);
  border: 0;
  box-shadow: var(--shadow-md);
}

.portfolio .portfolio-wrap img {
  display: block;
  width: 100%;
  transition: transform 0.5s var(--ease);
}

.portfolio .portfolio-wrap::before {
  content: "";
  background: linear-gradient(160deg, rgba(15, 23, 42, 0.15) 0%, rgba(15, 23, 42, 0.88) 100%);
  position: absolute;
  inset: 0;
  transition: all ease-in-out 0.4s var(--ease);
  z-index: 2;
  opacity: 0;
}

.portfolio .portfolio-wrap .portfolio-info {
  opacity: 0;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  text-align: center;
  z-index: 3;
  transition: all ease-in-out 0.35s var(--ease);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 20px;
  transform: translateY(8px);
}

.portfolio .portfolio-wrap .portfolio-info::before,
.portfolio .portfolio-wrap .portfolio-info::after {
  display: none;
}

.portfolio .portfolio-wrap .portfolio-info h4 {
  font-size: 1.05rem;
  color: #fff;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}

.portfolio .portfolio-wrap .portfolio-info p {
  color: #cbd5e1;
  font-size: 13px;
  text-transform: none;
  padding: 0;
  margin: 0;
}

.portfolio .portfolio-wrap .portfolio-links {
  text-align: center;
  z-index: 4;
  margin-top: 12px;
}

.portfolio .portfolio-wrap .portfolio-links a {
  color: #fff;
  margin: 0 4px;
  font-size: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.3s var(--ease);
}

.portfolio .portfolio-wrap .portfolio-links a:hover {
  color: #fff;
  background: var(--primary);
  border-color: transparent;
  transform: scale(1.08);
}

.portfolio .portfolio-wrap:hover::before {
  opacity: 1;
}

.portfolio .portfolio-wrap:hover img {
  transform: scale(1.06);
}

.portfolio .portfolio-wrap:hover .portfolio-info {
  opacity: 1;
  transform: translateY(0);
}

/* Featured portfolio */
.portfolio-featured {
  margin-bottom: 56px;
}

.portfolio-featured-hero {
  margin-bottom: 12px;
}

.portfolio-featured-card {
  display: block;
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  aspect-ratio: 16 / 10;
  background: transparent;
  border: 0;
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

.portfolio-featured-card--hero {
  aspect-ratio: 21 / 9;
  border-radius: calc(var(--radius-lg) + 4px);
  box-shadow: var(--shadow-glow);
}

.portfolio-featured-card--hero .portfolio-featured-content {
  padding: 40px 44px;
}

.portfolio-featured-card--hero .portfolio-featured-content h3 {
  font-size: clamp(1.75rem, 3.5vw, 2.35rem);
}

.portfolio-featured-card--hero .portfolio-featured-content p {
  font-size: 1.05rem;
  max-width: 520px;
}

.portfolio-featured-card--hero .portfolio-featured-tag {
  font-size: 12px;
  padding: 6px 14px;
}

.portfolio-featured-secondary {
  margin-top: 8px;
}

.portfolio-featured-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s var(--ease);
}

.portfolio-featured-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(15, 23, 42, 0.92) 0%,
    rgba(15, 23, 42, 0.4) 42%,
    rgba(15, 23, 42, 0.1) 100%
  );
  transition: background 0.4s var(--ease);
}

.portfolio-featured-content {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 28px;
  z-index: 2;
}

.portfolio-featured-content h3 {
  color: #fff;
  font-size: 1.45rem;
  font-weight: 700;
  margin: 10px 0 0;
  letter-spacing: -0.02em;
}

.portfolio-featured-content p {
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.9rem;
  margin: 8px 0 0;
  line-height: 1.5;
}

.portfolio-featured-tag {
  display: inline-block;
  background: linear-gradient(135deg, var(--primary), #6366f1);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.35);
}

.portfolio-featured-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 50px rgba(59, 130, 246, 0.28);
}

.portfolio-featured-card:hover img {
  transform: scale(1.05);
}

.portfolio-featured-card:hover::after {
  background: linear-gradient(
    to top,
    rgba(15, 23, 42, 0.95) 0%,
    rgba(37, 99, 235, 0.28) 50%,
    transparent 100%
  );
}

/* Research papers */
.portfolio-papers {
  margin-bottom: 56px;
  padding-top: 40px;
  padding-bottom: 10px;
  border-top: 1px solid var(--border);
}

.portfolio-papers-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
  letter-spacing: -0.02em;
}

.portfolio-papers-subtitle {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 28px;
}

.portfolio-paper-card {
  display: flex;
  align-items: stretch;
  gap: 0;
  height: 100%;
  background: var(--surface-2);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s var(--ease);
}

.portfolio-paper-thumb {
  flex: 0 0 38%;
  max-width: 38%;
  background: var(--text);
  overflow: hidden;
}

.portfolio-paper-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease);
}

.portfolio-paper-body {
  flex: 1;
  padding: 24px 26px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.portfolio-paper-tag {
  display: inline-block;
  color: var(--primary);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 8px;
}

.portfolio-paper-body h4 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 10px;
  letter-spacing: -0.02em;
}

.portfolio-paper-body p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 0;
}

.portfolio-paper-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
  border-color: rgba(59, 130, 246, 0.28);
}

.portfolio-paper-card:hover .portfolio-paper-thumb img {
  transform: scale(1.05);
}

@media (max-width: 767px) {
  .portfolio-paper-card {
    flex-direction: column;
  }
  .portfolio-paper-thumb {
    flex: none;
    max-width: 100%;
    aspect-ratio: 16 / 9;
  }
}

/* More projects */
.portfolio-more {
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.portfolio-more-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-soft);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 20px;
}

.portfolio-more-grid .portfolio-item {
  margin-bottom: 20px;
}

.portfolio-more-grid .portfolio-wrap {
  border-radius: var(--radius-sm);
  opacity: 0.92;
}

.portfolio-more-grid .portfolio-wrap .portfolio-info h4 {
  font-size: 0.95rem;
}

.portfolio-more-grid .portfolio-wrap .portfolio-links a {
  font-size: 16px;
  width: 38px;
  height: 38px;
}

.portfolio-more-grid .portfolio-wrap:hover {
  opacity: 1;
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

@media (max-width: 767px) {
  .portfolio-featured-card--hero {
    aspect-ratio: 16 / 10;
  }
  .portfolio-featured-card--hero .portfolio-featured-content h3 {
    font-size: 1.5rem;
  }
  .portfolio-featured-card--hero .portfolio-featured-content {
    padding: 24px;
  }
  .portfolio-featured-content h3 {
    font-size: 1.25rem;
  }
  .portfolio-featured-content {
    padding: 20px;
  }
  .portfolio #portfolio-flters {
    margin-left: 4%;
    margin-right: 4%;
    border-radius: var(--radius-md);
  }
}

/*--------------------------------------------------------------
# Portfolio Details
--------------------------------------------------------------*/
.portfolio-details {
  padding-top: 40px;
  background: var(--surface-2);
}

.portfolio-details .portfolio-details-slider img {
  width: 100%;
  border-radius: var(--radius-md);
}

.portfolio-details .portfolio-details-slider .swiper-pagination {
  margin-top: 20px;
  position: relative;
}

.portfolio-details .portfolio-details-slider .swiper-pagination .swiper-pagination-bullet {
  width: 10px;
  height: 10px;
  background-color: #fff;
  opacity: 1;
  border: 1px solid var(--primary);
  transition: all 0.25s var(--ease);
}

.portfolio-details .portfolio-details-slider .swiper-pagination .swiper-pagination-bullet-active {
  background: linear-gradient(135deg, var(--primary), #6366f1);
  border-color: transparent;
  transform: scale(1.15);
}

.portfolio-details .portfolio-info {
  padding: 28px;
  background: var(--surface);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}

.portfolio-details .portfolio-info h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
  letter-spacing: -0.02em;
}

.portfolio-details .portfolio-info ul {
  list-style: none;
  padding: 0;
  font-size: 15px;
  color: var(--text-muted);
}

.portfolio-details .portfolio-info ul li + li {
  margin-top: 12px;
}

.portfolio-details .portfolio-description {
  padding-top: 28px;
}

.portfolio-details .portfolio-description h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.portfolio-details .portfolio-description p {
  padding: 0;
  color: var(--text-muted);
  line-height: 1.75;
}

/*--------------------------------------------------------------
# Services
--------------------------------------------------------------*/
.services .icon-box {
  text-align: center;
  padding: 48px 24px;
  transition: all ease-in-out 0.35s var(--ease);
  background: var(--surface);
  box-shadow: var(--shadow-md);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
}
.services .icon-box .icon {
  margin: 0 auto;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: ease-in-out 0.3s;
  position: relative;
  border-radius: var(--radius-full);
  background: var(--surface-3);
}
.services .icon-box .icon i {
  font-size: 32px;
  transition: 0.5s;
  position: relative;
}
.services .icon-box .icon svg {
  position: absolute;
  top: 0;
  left: 0;
}
.services .icon-box .icon svg path {
  transition: 0.5s;
  fill: #f5f5f5;
}
.services .icon-box h4 {
  font-weight: 600;
  margin: 16px 0 12px;
  font-size: 1.2rem;
}
.services .icon-box h4 a {
  color: var(--text);
  transition: ease-in-out 0.3s;
}
.services .icon-box p {
  line-height: 1.6;
  font-size: 14px;
  margin-bottom: 0;
  color: var(--text-muted);
}
.services .icon-box:hover {
  border-color: rgba(59, 130, 246, 0.25);
  box-shadow: var(--shadow-glow);
  transform: translateY(-4px);
}
.services .iconbox-blue i { color: #47aeff; }
.services .iconbox-blue:hover .icon i { color: #fff; }
.services .iconbox-blue:hover .icon path { fill: #47aeff; }
.services .iconbox-orange i { color: #ffa76e; }
.services .iconbox-orange:hover .icon i { color: #fff; }
.services .iconbox-orange:hover .icon path { fill: #ffa76e; }
.services .iconbox-pink i { color: #e80368; }
.services .iconbox-pink:hover .icon i { color: #fff; }
.services .iconbox-pink:hover .icon path { fill: #e80368; }
.services .iconbox-yellow i { color: #ffbb2c; }
.services .iconbox-yellow:hover .icon i { color: #fff; }
.services .iconbox-yellow:hover .icon path { fill: #ffbb2c; }
.services .iconbox-red i { color: #ff5828; }
.services .iconbox-red:hover .icon i { color: #fff; }
.services .iconbox-red:hover .icon path { fill: #ff5828; }
.services .iconbox-teal i { color: #11dbcf; }
.services .iconbox-teal:hover .icon i { color: #fff; }
.services .iconbox-teal:hover .icon path { fill: #11dbcf; }

/*--------------------------------------------------------------
# Testimonials
--------------------------------------------------------------*/
.testimonials .section-header {
  margin-bottom: 40px;
}
.testimonials .testimonials-carousel,
.testimonials .testimonials-slider {
  overflow: hidden;
}
.testimonials .testimonial-item {
  text-align: center;
}
.testimonials .testimonial-item .testimonial-img {
  width: 120px;
  border-radius: 50%;
  border: 4px solid #fff;
  margin: 0 auto;
  box-shadow: var(--shadow-md);
}
.testimonials .testimonial-item h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 12px 0 4px;
  color: var(--text);
}
.testimonials .testimonial-item h4 {
  font-size: 14px;
  color: var(--text-muted);
  margin: 0 0 15px;
}
.testimonials .testimonial-item .quote-icon-left,
.testimonials .testimonial-item .quote-icon-right {
  color: #93c5fd;
  font-size: 26px;
}
.testimonials .testimonial-item .quote-icon-left {
  display: inline-block;
  left: -5px;
  position: relative;
}
.testimonials .testimonial-item .quote-icon-right {
  display: inline-block;
  right: -5px;
  position: relative;
  top: 10px;
}
.testimonials .testimonial-item p {
  font-style: italic;
  margin: 0 auto 15px;
  color: var(--text-muted);
}
.testimonials .swiper-pagination {
  margin-top: 20px;
  position: relative;
}
.testimonials .swiper-pagination .swiper-pagination-bullet {
  width: 10px;
  height: 10px;
  background-color: #fff;
  opacity: 1;
  border: 1px solid var(--primary);
}
.testimonials .swiper-pagination .swiper-pagination-bullet-active {
  background: linear-gradient(135deg, var(--primary), #6366f1);
  border-color: transparent;
}
@media (min-width: 992px) {
  .testimonials .testimonial-item p {
    width: 80%;
  }
}

/*--------------------------------------------------------------
# Contact
--------------------------------------------------------------*/
.contact .info {
  width: 100%;
  background: var(--surface);
  padding: 28px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
}
.contact .info i {
  font-size: 20px;
  color: var(--primary);
  float: left;
  width: 48px;
  height: 48px;
  background: var(--primary-soft);
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: var(--radius-full);
  transition: all 0.3s var(--ease);
}
.contact .info h4 {
  padding: 0 0 0 64px;
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 5px;
  color: var(--text);
}
.contact .info p {
  padding: 0 0 0 64px;
  margin-bottom: 0;
  font-size: 14px;
  color: var(--text-muted);
}
.contact .info .email,
.contact .info .phone {
  margin-top: 36px;
}
.contact .info .email:hover i,
.contact .info .address:hover i,
.contact .info .phone:hover i {
  background: linear-gradient(135deg, var(--primary), #6366f1);
  color: #fff;
  box-shadow: var(--shadow-glow);
}
.contact .php-email-form {
  width: 100%;
  background: var(--surface);
  padding: 28px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
}
.contact .php-email-form .form-group {
  padding-bottom: 8px;
}
.contact .php-email-form .error-message {
  display: none;
  color: #fff;
  background: #ed3c0d;
  text-align: left;
  padding: 15px;
  font-weight: 600;
  border-radius: var(--radius-sm);
}
.contact .php-email-form .error-message br + br {
  margin-top: 25px;
}
.contact .php-email-form .sent-message {
  display: none;
  color: #fff;
  background: #18d26e;
  text-align: center;
  padding: 15px;
  font-weight: 600;
  border-radius: var(--radius-sm);
}
.contact .php-email-form .loading {
  display: none;
  background: #fff;
  text-align: center;
  padding: 15px;
}
.contact .php-email-form .loading:before {
  content: "";
  display: inline-block;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  margin: 0 10px -6px 0;
  border: 3px solid #18d26e;
  border-top-color: #eee;
  animation: animate-loading 1s linear infinite;
}
.contact .php-email-form input,
.contact .php-email-form textarea {
  border-radius: var(--radius-sm);
  box-shadow: none;
  font-size: 14px;
  border: 1px solid var(--border-strong);
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.contact .php-email-form input:focus,
.contact .php-email-form textarea:focus {
  border-color: rgba(59, 130, 246, 0.45);
  box-shadow: 0 0 0 3px var(--primary-soft);
  outline: none;
}
.contact .php-email-form input {
  height: 46px;
}
.contact .php-email-form textarea {
  padding: 12px 14px;
}
.contact .php-email-form button[type=submit] {
  background: linear-gradient(135deg, var(--primary), #6366f1);
  border: 0;
  padding: 12px 32px;
  color: #fff;
  transition: all 0.35s var(--ease);
  border-radius: var(--radius-full);
  font-weight: 600;
  box-shadow: var(--shadow-glow);
}
.contact .php-email-form button[type=submit]:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(59, 130, 246, 0.4);
}

@keyframes animate-loading {
  to { transform: rotate(360deg); }
}

/*--------------------------------------------------------------
# Footer
--------------------------------------------------------------*/
#footer {
  background: linear-gradient(180deg, var(--surface-2) 0%, #eef2ff 100%);
  color: var(--text-muted);
  font-size: 14px;
  text-align: center;
  padding: 48px 0 36px;
  border-top: 1px solid var(--border);
}

#footer h3 {
  font-size: 1.75rem;
  font-weight: 700;
  position: relative;
  font-family: var(--font-display);
  padding: 0;
  margin: 0 0 12px;
  color: var(--text);
  letter-spacing: -0.02em;
}

#footer p {
  font-size: 15px;
  font-style: normal;
  padding: 0;
  margin: 0 0 28px;
  color: var(--text-muted);
}

#footer .social-links {
  margin: 0 0 28px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

#footer .social-links a {
  font-size: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  color: var(--text-muted);
  line-height: 1;
  border-radius: var(--radius-full);
  width: 42px;
  height: 42px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: all 0.3s var(--ease);
}

#footer .social-links a:hover {
  background: linear-gradient(135deg, var(--primary), #6366f1);
  color: #fff;
  border-color: transparent;
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
  text-decoration: none;
}

#footer .copyright {
  margin: 0 0 4px;
  color: var(--text);
  font-size: 0.95rem;
}

#footer .credits {
  font-size: 13px;
  color: var(--text-soft);
}
