/* Portfolio Styles */
/* Design System */
:root {
    --primary: #2d4cbc;
    --primary-dark: #230070;
    --primary-light: #4b71ec; /* ← lighter, softer teal */
    --secondary: #3e33d5;
    --background: #FAFAFA;
    --foreground: #0B1220;
    --muted: #6B7280;
    --border: #E5E7EB;
    --white: #ffffff;
    --radius: 12px;
    --shadow-sm: 0 2px 8px rgba(11, 17, 34, 0.04);
    --shadow-md: 0 4px 12px rgba(11, 17, 34, 0.06);
    --shadow-lg: 0 6px 16px rgba(11, 17, 34, 0.08);
    --shadow-xl: 0 8px 24px rgba(11, 17, 34, 0.12);
}


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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--foreground);
    background-color: var(--background);
}

/* Typography */
h1 {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h2 {
    font-size: 2.25rem;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 0.75rem;
}

h3 {
    font-size: 1.5rem;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 0.5rem;
}

p {
    margin-bottom: 1rem;
}

/* Container */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: transparent;
    transition: all 0.3s ease;
}

.header.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
}

.nav-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}


.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    cursor: default; /* not clickable */
}

.logo-icon {
    display: none !important;
}

.logo-text {
    display: inline;
    font-weight: 600;
    color: var(--primary); /* highlighted like Download Resume */
}


.nav-links {
    display: none;
    gap: 0.25rem;
}

.nav-link {
    padding: 0.5rem 0.75rem;
    color: var(--muted);
    text-decoration: none;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: var(--primary);
}

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

.mobile-menu-btn {
    display: block;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    max-width: 400px;
    height: 100vh;
    background-color: var(--white);
    box-shadow: var(--shadow-xl);
    z-index: 2000;
    transition: right 0.3s ease;
}

.mobile-menu.active {
    right: 0;
}

.mobile-menu-content {
    padding: 2rem;
}

.mobile-menu-close {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--foreground);
    margin-bottom: 2rem;
}

.mobile-nav {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.mobile-nav-link {
    padding: 0.75rem;
    color: var(--muted);
    text-decoration: none;
    font-size: 1.125rem;
    transition: color 0.2s ease;
}

.mobile-nav-link:hover {
    color: var(--primary);
}

.mobile-menu-actions {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    border: none;
    font-size: 1rem;
    gap: 0.5rem;
}

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

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary);
    color: var(--white);
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

.btn-large {
    padding: 1rem 2rem;
}

.btn-block {
    width: 100%;
}

.icon {
    flex-shrink: 0;
}

/* Dropdown */
.dropdown {
    position: relative;
    display: none;
}

.dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    background-color: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
}

.dropdown:hover .dropdown-menu,
.dropdown-toggle:focus + .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: block;
    padding: 0.75rem 1rem;
    color: var(--foreground);
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.dropdown-item:hover {
    background-color: var(--background);
}

/* Sections */
.section {
    padding: 5rem 1rem;
}

.section-white {
    background-color: var(--white);
}

.section-gray {
    background-color: var(--background);
}

/* === Global Section Header Alignment & Styling === */
.section-header {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.section-header h2 {
  margin-bottom: 0.5rem;
  font-weight: 600;
  text-align: center;
}

.section-divider {
  width: 80px;
  height: 4px;
  background-color: var(--primary);
  border-radius: 2px;
  margin: 0.5rem auto;
}

.section-header .section-subtitle {
  width: 100%;
  max-width: 700px;
  text-align: center;
  margin: 0.75rem auto 0 auto;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.6;
}

/* === Force Center Alignment for Expertise Section Header === */
#expertise .section-header {
  text-align: center !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
}

#expertise .section-header .section-subtitle {
  text-align: center !important;
  margin: 0.75rem auto 0 auto !important;
  width: 100%;
  max-width: 700px;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.6;
}

/* Hero */
.hero {
    padding-top: 8rem;
    padding-bottom: 5rem;
    background: linear-gradient(to bottom, var(--white), var(--background));
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: center;
}

.hero-image {
    display: flex;
    justify-content: center;
    position: relative;
}

.portrait-frame {
    width: 288px;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    border: 4px solid var(--white);
    position: relative;
    z-index: 1;
    height: auto; /* allow natural height */
}

.portrait-frame img {
    width: 100%;
    height: auto;
    object-fit: contain;
}

.decorative-blur {
    position: absolute;
    border-radius: var(--radius);
    filter: blur(48px);
    z-index: 0;
}

.decorative-blur-1 {
    width: 96px;
    height: 96px;
    background-color: rgba(0, 124, 137, 0.1);
    bottom: -1rem;
    right: -1rem;
}

.decorative-blur-2 {
    width: 128px;
    height: 128px;
    background-color: rgba(43, 103, 119, 0.1);
    top: -1rem;
    left: -1rem;
}

.hero-content {
    text-align: center;
}

.hero-subtitle {
    color: var(--primary);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.hero-description {
    color: var(--muted);
    margin-bottom: 2rem;
}

.hero-actions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
}

.dropdown-item {
    display: block;
    padding: 0.75rem 1rem;
    color: var(--foreground);
    text-decoration: none;
    transition: background-color 0.2s ease;
    text-align: center;      /* 👈 Center-align dropdown text */
}

/* Card */
.card {
    background-color: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.card:hover {
    box-shadow: var(--shadow-lg);
}

/* Expertise */
.expertise-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}




/* Timeline */
.timeline-container {
    max-width: 56rem;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.timeline-item {
    transition: all 0.3s ease;
}

.timeline-item.selected {
    border: 2px solid var(--primary) !important;
}

.timeline-header {
    display: flex;
    gap: 1rem;
}

.timeline-icon {
    width: 48px;
    height: 48px;
    background-color: rgba(0, 124, 137, 0.1);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.timeline-content {
    flex: 1;
}

.timeline-company {
    margin-bottom: 0.25rem;
}

.timeline-role {
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.timeline-location {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--muted);
    font-size: 0.875rem;
}

.timeline-years {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background-color: rgba(0, 124, 137, 0.1);
    color: var(--primary);
    border-radius: 9999px;
    font-size: 0.875rem;
}

.timeline-highlights {
    list-style: none;
    margin: 1rem 0;
}

.timeline-highlight {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
    color: var(--muted);
}

.timeline-bullet {
    width: 6px;
    height: 6px;
    background-color: var(--primary);
    border-radius: 50%;
    margin-top: 0.5rem;
    flex-shrink: 0;
}

.timeline-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

/* Stories */
.filter-tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 3rem;
}

.filter-tab {
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background-color: transparent;
    color: var(--muted);
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-tab:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.filter-tab.active {
    background-color: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

.filter-title {
    color: var(--primary) !important;
}

.stories-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.story-card {
    overflow: hidden;
}

.story-image {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.story-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.story-card:hover .story-image img {
    transform: scale(1.1);
}

.story-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.2), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.story-card:hover .story-overlay {
    opacity: 1;
}


.story-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.story-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.75rem;
    font-size: 0.875rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--muted);
    background-color: rgba(0, 124, 137, 0.05);
    cursor: pointer;
    transition: all 0.25s ease;
}

.story-tag:hover {
    background-color: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

.icon-sm {
    width: 16px;
    height: 16px;
}


.story-content h3 {
    margin-bottom: 0.75rem;
    transition: color 0.3s ease;
}

.story-card:hover h3 {
    color: var(--primary);
}

.story-content p {
    color: var(--muted);
    margin-bottom: 1rem;
}

/* Container for extra expertise tags */
.highlighted-tags {
  margin: 0.5rem 0 0.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

/* Individual extra expertise tags */
.custom-tag {
    background-color: rgba(0, 124, 137, 0.1); /* Light teal background */
    color: var(--primary);                     /* Use primary color for text */
    padding: 0.25rem 0.5rem;                  /* Top/bottom and left/right padding */
    font-size: 0.75rem;                        /* Slightly smaller font */
    border-radius: 4px;                        /* Rounded corners */
    font-weight: 500;                          /* Slightly bold text */
}

/* Highlighted Expertise Tags in Success Stories */
.highlighted-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.highlighted-tags .custom-tag {
  background: rgba(0, 124, 137, 0.08);
  color: var(--primary);
  border-radius: 9999px;
  padding: 0.25rem 0.6rem;
  font-size: 0.75rem;
  font-weight: 500;
}


/* === Education Timeline (Icon Inside + Perfect Alignment) === */

.education-grid {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  max-width: 64rem;
  margin: 0 auto;
  padding-left: 2.5rem;
}

/* Vertical timeline spine */
.education-grid::before {
  content: '';
  position: absolute;
  left: 1.25rem;
  top: 0;
  bottom: 0;
  width: 2px;
  background-color: var(--border);
}

/* Card container */
.education-card {
  position: relative;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 1.25rem 1.5rem 1.5rem 1.5rem;
  transition: all 0.3s ease;
}

.education-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

/* Header: Icon + Title + Meta */
.education-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 0.5rem;
}

/* Icon now inside card (aligned with title) */
.education-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
}

/* Internal icon — sits flush with text baseline */
.education-icon {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  background-color: rgba(0, 124, 137, 0.1);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--primary);
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.education-card:hover .education-icon {
  background-color: var(--primary);
  color: var(--white);
}

/* Degree title beside icon */
.education-degree {
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.3;
  transition: color 0.3s ease;
}

.education-card:hover .education-degree {
  color: var(--primary);
}

/* Meta info — neatly aligned on right side */
.education-meta {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-shrink: 0;
  margin-top: 0.2rem;
}

.education-location,
.education-years {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.9rem;
  line-height: 1;
}

.education-location {
  color: var(--muted);
}

.education-location svg,
.education-years svg {
  width: 16px;
  height: 16px;
  color: var(--primary);
}

.education-years {
  background-color: rgba(0, 124, 137, 0.08);
  color: var(--primary);
  font-weight: 500;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  white-space: nowrap;
}

/* School & description aligned under title (no icon offset needed now) */
.education-body {
  margin-left: 3.2rem; /* aligns text perfectly under degree, not under icon */
  margin-top: 0.4rem;
}

.education-school {
  color: var(--primary);
  font-weight: 500;
  margin-bottom: 0.35rem;
  display: block;
}

.education-description {
  margin-top: 0.5rem;
  padding-left: 1rem; /* soft indent for list, relative to school text */
  list-style-type: disc;
  color: var(--muted);
  line-height: 1.6;
}

.education-description li {
  margin-bottom: 0.4rem;
  text-align: justify;
}


/* Responsive alignment for larger screens */
@media (min-width: 1024px) {
  .education-grid {
    padding-left: 3rem;
  }

  .education-icon {
    left: -0.5rem;
  }
}

/* Company Success Stories Tabs */
#companyStoriesTabs {
    margin-top: 2rem;
}

#companyTabsList {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 2rem;
}

#companyTabsList .tab-trigger.active {
    background-color: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

#companyStoriesContent .tabs-content {
    display: none;
}

#companyStoriesContent .tabs-content.active {
    display: block;
}

.story-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  color: var(--foreground);
}

.company-name {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--primary);
}
/* Success Stories (Narrative version) */
.story-narrative {
  padding: 2rem;
  border-radius: 1rem;
  background: var(--card-bg, #fff);
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  line-height: 1.6;
}

.story-narrative h3 {
  margin-bottom: 1rem;
  font-size: 1.25rem;
  color: var(--text-primary);
}

.story-narrative p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.story-themes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}


.theme-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(0,124,137,0.08);
  color: var(--primary);
  border-radius: 2rem;
  padding: 0.4rem 0.8rem;
  font-size: 0.85rem;
}

/* Sub-tabs for expertise stories */
.sub-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
  justify-content: center;
}

.sub-tab {
  padding: 0.5rem 1rem;
  border: 1px solid var(--border);
  border-radius: 2rem;
  background: transparent;
  cursor: pointer;
  transition: 0.3s;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
}

.sub-tab.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.sub-story {
  display: none;
  animation: fadeIn 0.3s ease;
}
.sub-story.active {
  display: block;
}

.area-stories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 1.5rem;
}

.story-narrative {
  padding: 1.5rem;
  border-radius: 1rem;
  background: var(--card-bg, #fff);
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  transition: transform 0.2s ease;
}

.story-narrative:hover {
  transform: translateY(-4px);
}

.story-narrative h3 {
  margin-bottom: 0.75rem;
  font-size: 1.1rem;
  color: var(--text-primary);
}

.story-narrative p {
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Expertise-Based Success Stories Tabs */
#expertiseStoriesTabs {
  margin-top: 2rem;
}


#expertiseTabsList .tab-trigger.active {
  background-color: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

#expertiseStoriesContent .tabs-content {
  display: none;
}

#expertiseStoriesContent .tabs-content.active {
  display: block;
}

/* Company group styling inside each expertise tab */
.company-group {
  margin-bottom: 2.5rem;
}

.company-group h3 {
  color: var(--primary);
  margin-bottom: 1rem;
  text-align: center;
}

.area-stories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 1.5rem;
}

/* Pulse glow effect when tab auto-activates */
.pulse-glow {
  box-shadow: 0 0 10px 3px rgba(0, 124, 137, 0.5);
  animation: pulseGlow 0.8s ease-in-out;
}

@keyframes pulseGlow {
  0% { box-shadow: 0 0 0px rgba(0, 124, 137, 0.6); }
  50% { box-shadow: 0 0 14px 4px rgba(0, 124, 137, 0.8); }
  100% { box-shadow: 0 0 0px rgba(0, 124, 137, 0.6); }
}

/* Story list layout without images */
.area-stories-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.story-text-block {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  transition: transform 0.2s ease;
}

.story-text-block:hover {
  transform: translateY(-3px);
}

.story-tag-title {
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

/* --- Text Justification for Story Content --- */
.story-text-block p,
.story-text-block,
.company-group p,
.section p,
.hero-description p,
.education-grid p,
#achievements p,
#expertise p,
#featured-projects p,
#timeline p {
  text-align: justify;
  text-justify: inter-word;
}

#featured-projects {
  display: none    !important;
}

/* Achievements */
.tabs-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 3rem;
    background-color: transparent;
}

.tab-trigger {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background-color: transparent;
    color: var(--foreground);
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-trigger:hover {
    border-color: var(--primary);
}

.tab-trigger.active {
    background-color: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

.tabs-content {
    display: none;
}

.tabs-content.active {
    display: block;
}

/* ✅ FINAL Expertise Tabs Layout Fix */
#expertiseTabsList {
  display: flex;
  flex-wrap: wrap; /* ✅ allows wrapping on smaller screens instead of overflow */
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 2rem;
  padding: 0.5rem 1rem;
}

/* Scrollbar style (optional aesthetic touch) */
#expertiseTabsList::-webkit-scrollbar {
  height: 6px;
}
#expertiseTabsList::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}

#expertiseTabsList .tab-trigger:hover {
  background: rgba(0, 124, 137, 0.05);
  border-color: var(--primary);
}

/* ✅ Base styling for each expertise tab trigger */
#expertiseTabsList .tab-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: 2rem;
  padding: 0.6rem 1.2rem;
  font-size: 0.95rem;
  line-height: 1;
  color: var(--foreground);
  white-space: nowrap; /* ✅ keeps text on same line */
  cursor: pointer;
  transition: all 0.25s ease;
  flex-shrink: 0;
  text-align: center;
}

#expertiseTabsList .tab-trigger.active {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

/* Ensure icons are correctly aligned */
#expertiseTabsList .tab-trigger svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  vertical-align: middle;
  display: inline-block;
  position: relative;
  top: 1px;
}



.achievements-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.achievement-card {
    position: relative;
}

.achievement-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.achievement-year {
    flex-shrink: 0;
    padding: 0.25rem 0.75rem;
    background-color: rgba(0, 124, 137, 0.1);
    color: var(--primary);
    border-radius: 9999px;
    font-size: 0.875rem;
}

.achievement-org {
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.achievement-desc {
    color: var(--muted);
}

.achievement-underline {
    height: 4px;
    background-color: var(--primary);
    border-radius: 2px;
    margin-top: 1rem;
    width: 0;
    transition: width 0.3s ease;
}

.achievement-card:hover .achievement-underline {
    width: 100%;
}

.achievement-list {
  margin-top: 0.5rem;
  padding-left: 1.25rem;
  list-style-type: disc;
  color: var(--muted);
  line-height: 1.6;
}

.achievement-list li {
  margin-bottom: 0.35rem;
  text-align: justify;
}



.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 500;
    color: var(--foreground);
}

.form-group input,
.form-group textarea {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.2s ease;
    background-color: var(--white);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0, 124, 137, 0.1);
}

.form-group textarea {
    resize: none;
}

.success-message {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1rem;
    text-align: center;
}

.success-icon {
    width: 80px;
    height: 80px;
    background-color: rgba(34, 197, 94, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.success-icon svg {
    color: #22c55e;
}

.success-message h3 {
    margin-bottom: 0.5rem;
}

.success-message p {
    color: var(--muted);
    margin: 0;
}

.contact-info-header h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.contact-info-header p {
    color: var(--muted);
    margin-bottom: 2rem;
}

.contact-info-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-info-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background-color: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    text-decoration: none;
    transition: all 0.3s ease;
}

.contact-info-item:hover {
    box-shadow: var(--shadow-lg);
}

.contact-info-icon {
    width: 48px;
    height: 48px;
    background-color: rgba(0, 124, 137, 0.1);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.contact-info-item:hover .contact-info-icon {
    background-color: var(--primary);
    color: var(--white);
}

.contact-info-text {
    flex: 1;
}

.contact-info-label {
    font-size: 0.875rem;
    color: var(--muted);
    margin-bottom: 0.25rem;
}

.contact-info-value {
    color: var(--foreground);
    transition: color 0.3s ease;
}

.contact-info-item:hover .contact-info-value {
    color: var(--primary);
}

/* Footer */
.footer {
    background-color: var(--foreground);
    color: var(--white);
    padding: 3rem 1rem;
}

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

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    width: 40px;
    height: 40px;
    border-radius: var(--radius);
    background-color: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    background-color: var(--primary);
    transform: scale(1.1);
}

.copyright {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.7);
}


.back-to-top.visible {
    display: flex;
}

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

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

[data-animate="fade"].animated {
    animation: fadeIn 0.6s ease-out;
}

[data-animate="left"].animated {
    animation: fadeInLeft 0.6s ease-out;
}

[data-animate="right"].animated {
    animation: fadeInRight 0.6s ease-out;
}

/* Media Queries */
@media (min-width: 640px) {
    .logo-text {
        display: inline;
    }
    
    .portrait-frame {
        width: 320px;
        height: 420px;
    }
    
    .hero-actions {
        flex-direction: row;
    }
    
    .stories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .timeline-title-row {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
    }
    
    .contact-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-content {
        flex-direction: row;
        justify-content: space-between;
    }
}

@media (min-width: 1024px) {
    h1 {
        font-size: 4rem;
    }
    
    h2 {
        font-size: 2.5rem;
    }
    
    .nav-links {
        display: flex;
    }
    
    .mobile-menu-btn {
        display: none;
    }
    
    .dropdown {
        display: inline-block;
    }
    
    .hero-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 4rem;
    }
    
    .hero-content {
        text-align: left;
    }
    
    .hero-actions {
        justify-content: flex-start;
    }
    
    .hero-subtitle {
        font-size: 1.875rem;
    }
    
    .portrait-frame {
        width: 384px;
        height: 500px;
    }
    
    .expertise-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    }
    
    .stories-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .education-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .achievements-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.story-details {
  margin-top: 0.75rem;
}

.story-detail-paragraph {
  margin-bottom: 0.9rem;
  line-height: 1.6;
  color: var(--muted);
  text-align: justify;
}

.story-details.hidden {
  display: none;
}

.view-details-btn {
  margin-top: 0.5rem;
  background: #2563eb;
  color: white;
  border: none;
  border-radius: 0.5rem;
  padding: 0.5rem 1rem;
  cursor: pointer;
  transition: 0.3s;
}

.view-details-btn:hover {
  background: #1e40af;
}

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

.tag {
  background: #e0e7ff;
  color: #1e3a8a;
  padding: 0.3rem 0.7rem;
  border-radius: 9999px;
  font-size: 0.8rem;
}
/* Modal overlay fade */
.modal-overlay {
    background: rgba(11, 17, 34, 0.5); /* use dark overlay consistent with foreground */
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Modal content scale and shadow */
.modal-content {
    background: var(--white); /* main content stays white for readability */
    color: var(--foreground); /* use foreground color */
    padding: 2rem;
    border-radius: var(--radius);
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl); /* slightly stronger shadow */
    transform: scale(0.9);
    transition: transform 0.3s ease, background 0.3s ease, color 0.3s ease;
}

/* Smooth scale-in */
.modal-overlay.show {
    opacity: 1;
}
.modal-content.show {
    transform: scale(1);
}

/* Close button */
.close-modal {
    background: var(--border); /* light gray from design system */
    color: var(--foreground);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    cursor: pointer;
    transition: background 0.3s ease, color 0.3s ease, transform 0.2s ease;
}
.close-modal:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
}

/* Modal expertise tags */
.modal-content span {
    background: rgba(0, 124, 137, 0.1); /* light teal from design system */
    color: var(--primary); 
    padding: 0.3rem 0.6rem;
    border-radius: var(--radius);
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    cursor: default;
    transition: background 0.2s ease, transform 0.2s ease;
}
.modal-content span:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-1px);
}

/* Titles/indicators in modal */
.modal-content h3 {
    margin-bottom: 0.75rem;
    color: var(--primary);
    font-size: 1.25rem;
}

.modal-content h4 {
    margin-bottom: 0.5rem;
    color: var(--secondary);
    font-size: 1rem;
    font-weight: 600;
}


/* Story card */
.story-card {
  position: relative;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 1.5rem 1.5rem 1.5rem 1.75rem; /* extra left padding */
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.story-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.08);
}

/* Timeline-style accent */
.story-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 1.25rem;
  bottom: 1.25rem;
  width: 3px;
  border-radius: 2px;
  background: rgba(0, 124, 137, 0.25); /* muted primary */
}
/* Preview text */
.story-preview {
  font-style: italic;
  color: var(--muted);
  line-height: 1.65;
  margin: 0.5rem 0 0.75rem;
}
/* Expandable section */
.story-details {
  overflow: hidden;
  transition: opacity 0.25s ease;
}

.story-details.hidden {
  display: none;
}
/* Read more / less button */
.read-toggle {
  margin-top: 0.5rem;
  padding: 0;
  background: none;
  border: none;
  color: var(--primary);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  align-self: flex-start;
}

.read-toggle:hover {
  text-decoration: underline;
}

.story-card.expanded .story-details {
  opacity: 1;
}
.story-card.expanded::before {
  background: var(--primary); /* stronger accent when open */
}

.story-image-wrapper {
  width: 700px;   /* fixed width */
  height: 400px;  /* fixed height */
  margin: 0.5rem auto 0.75rem;
  border: 1px solid rgba(0, 102, 204, 0.25); /* blue minimalist border */
  border-radius: 12px;
  background: #ffffff;
  overflow: hidden; /* ensures image stays inside */
  display: flex;
  justify-content: center;
  align-items: center;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.story-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* fills container, crops if necessary */
  display: block;
  border-radius: 10px;
  transition: transform 0.25s ease;
}

.story-card .story-image-wrapper img {
  visibility: hidden;
}

/* Hover effect */
.story-image-wrapper:hover {
  border-color: rgba(0, 102, 204, 0.6);
  box-shadow: 0 4px 12px rgba(0, 102, 204, 0.15);
  transform: translateY(-1px);
}

.story-image-wrapper:hover img {
  transform: scale(1.03);
}

/* === Grid Layout === */
.expertise-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.8rem;
}

/* === Card Base === */
.expertise-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem; /* Padding added so image does NOT touch edges */
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  cursor: pointer;
}

.expertise-card:hover {
  transform: translateY(-6px) scale(1.015);
  box-shadow: var(--shadow-lg);
}

/* === Image Container (with rounded + gap) === */
.expertise-image {
  width: 100%;
  height: 160px;
  margin-bottom: 1rem;
  border-radius: 12px;             /* rounded corners */
  overflow: hidden;                /* makes image respect rounding */
}

.expertise-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.expertise-card:hover .expertise-image img {
  transform: scale(1.08);
}

/* === Content Section === */
.expertise-content {
  padding: 0 0.25rem 0.5rem 0.25rem; /* subtle content spacing */
}

/* === Icon + Title === */
.expertise-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.expertise-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  background-color: rgba(0, 124, 137, 0.12);
  color: var(--primary);
  transition: background 0.25s ease, transform 0.25s ease;
}

.expertise-card:hover .expertise-icon {
  background-color: rgba(0, 124, 137, 0.18);
  transform: rotate(3deg);
}

.expertise-header h3 {
  margin: 0;
  color: var(--foreground);
  font-weight: 600;
  font-size: 1.1rem;
  line-height: 1.3;
}

/* === Description Text === */
.expertise-card p {
  color: var(--muted);
  text-align: justify;
  text-justify: inter-word;
  margin: 0;
  line-height: 1.58;
}



/* --- Timeline Multi-Role Layout --- */
.role-block {
  border-top: 1px solid var(--border);
  padding-top: 1rem;
  margin-top: 1rem;
}

.role-block:first-child {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
}

.role-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.role-header h4 {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--foreground);
}

.role-header .timeline-years {
  font-size: 0.9rem;
  color: var(--primary);
}
.role-title-group {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.role-location {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* === Timeline Header Consistency Fix === */
.timeline-title-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start; /* aligns top edges neatly */
  flex-wrap: wrap;
  gap: 0.25rem 1rem;
}

.timeline-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
  gap: 0.2rem;
}

.timeline-company {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-dark);
}

.timeline-location {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  color: var(--muted);
  font-size: 0.9rem;
}


.timeline-years {
  background-color: rgba(0,124,137,0.1);
  color: var(--primary);
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  white-space: nowrap;
}
.timeline-title-group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.25rem;
}

.timeline-title-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}

.education-meta {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-top: 0.25rem;
}

.education-location,
.education-years {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--primary);
  font-size: 0.95rem;
}

.education-description {
  margin-top: 0.75rem;
  padding-left: 1.25rem;
  list-style-type: disc;
  color: var(--muted);
  line-height: 1.6;
}

.education-description li {
  margin-bottom: 0.4rem;
  text-align: justify;
}

/* === SECTION COLOR LOGIC FIX === */

/* Default alternating background colors */
section.section-white {
  background-color: var(--white);
}

section.section-gray {
  background-color: var(--background);
}

/* Force Education and Achievements consistency */
#education,
#achievements {
  background-color: var(--white);
}

/* Hide Featured Projects but preserve layout color alternation */
#featured-projects {
  display: none; /* or block when needed */
}

/* When Featured Projects is hidden, automatically maintain correct alternation */
#featured-projects + section {
  background-color: var(--white);
}

/* === Conference Achievements Styling === */
.achievement-org {
  display: flex;
  align-items: center;
  gap: 0.4rem;              /* space between icon and text */
  color: var(--primary);
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.achievement-org svg {
  width: 16px;
  height: 16px;
  color: var(--primary);
  flex-shrink: 0;
  vertical-align: middle;
}

/* Optional — make descriptions consistent and readable */
.achievement-desc {
  color: var(--muted);
  text-align: justify;
  text-justify: inter-word;
  line-height: 1.6;
}

/* Keep underline animation consistent */
.achievement-underline {
  height: 4px;
  background-color: var(--primary);
  border-radius: 2px;
  margin-top: 1rem;
  width: 0;
  transition: width 0.3s ease;
}

.achievement-card:hover .achievement-underline {
  width: 100%;
}

/* === EB1 Visa Block Styling === */
.tabs-content[data-tab="eb1visa"] .achievements-grid {
  display: flex;
  justify-content: center;
}

.tabs-content[data-tab="eb1visa"] .achievement-card {
  max-width: 900px;
  width: 100%;
  text-align: justify;
  background-color: #f8f9fb;
  border: 1px solid var(--border);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  padding: 2rem;
  margin: 0 auto;
  border-radius: 12px;
}

/* Header alignment and spacing */
.tabs-content[data-tab="eb1visa"] .achievement-header {
  text-align: center;
  margin-bottom: 1rem;
}

.tabs-content[data-tab="eb1visa"] .achievement-header h3 {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--primary);
}

/* EB1 description paragraphs */
.tabs-content[data-tab="eb1visa"] .achievement-desc p {
  margin-bottom: 1rem;
  line-height: 1.7;
  text-align: justify;
  color: #333;
}


/* EB1 Visa Description Styling */
.eb1-visa-desc {
  animation: fadeIn 1s ease-out;
  color: var(--foreground);
  text-align: justify;
  text-justify: inter-word;
  line-height: 1.7;
}

.eb1-visa-desc p {
  margin-bottom: 1rem;
}

.text-primary {
  color: var(--primary);
  font-weight: 600;
}

/* === Publications Narrative with Top-Right Metadata === */
.tabs-content[data-tab="publications"] .achievements-grid {
  display: flex;
  justify-content: center;
}

.tabs-content[data-tab="publications"] .achievement-card {
  max-width: 900px;
  width: 100%;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  margin: 0 auto;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  animation: fadeIn 0.8s ease-out;
}

.tabs-content[data-tab="publications"] .achievement-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.tabs-content[data-tab="publications"] .achievement-header h3 {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--primary);
}

/* === Publications Section Unified Styling === */

/* Container for multiple publication cards */
.publication-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  margin-top: 1.5rem;
  width: 100%;
}

/* Each publication card block */
.publication-card {
  width: 90%;
  max-width: 900px;
  background: var(--white, #fff);
  border: 1px solid var(--border, #e0e0e0);
  border-radius: 14px;
  padding: 1.75rem 2rem;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
  position: relative;
}

.publication-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.08);
  background-color: rgba(250, 250, 250, 0.96);
}

/* Top section with title and year badge */
.publication-meta {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.publication-title {
  font-weight: 600;
  color: var(--foreground, #222);
  font-size: 1.1rem;
  margin: 0;
  line-height: 1.5;
  flex: 1;
  word-break: break-word;
}

/* Year pill badge */
.publication-year {
  background: rgba(0, 128, 128, 0.08);
  color: var(--primary, #007b83);
  font-weight: 600;
  font-size: 0.85rem;
  border-radius: 999px;
  padding: 0.25rem 0.75rem;
  min-width: 55px;
  text-align: center;
  white-space: nowrap;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.05);
}

/* Organization / conference info */
.publication-org {
  color: var(--primary, #007b83);
  font-weight: 500;
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  text-align: left;
}

/* Description text */
.publication-desc {
  color: var(--text-secondary, #333);
  text-align: justify;
  line-height: 1.7;
  font-size: 0.95rem;
  margin-top: 0.25rem;
}

/* === "View Publication" Button === */
.publication-link {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.6rem 1.2rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--primary, #007b83);
  border: 1px solid var(--primary, #007b83);
  border-radius: 8px;
  background: transparent;
  text-decoration: none;
  transition: all 0.3s ease;
}

.publication-link:hover {
  background: var(--primary, #007b83);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 128, 128, 0.15);
}

/* Divider line between publication entries (if reused) */
.publication-divider {
  border: 0;
  border-top: 1px solid var(--border, #ccc);
  margin: 1.25rem 0;
  opacity: 0.4;
}

/* === Responsive Adjustments === */
@media (max-width: 768px) {
  .publication-card {
    padding: 1.25rem 1.5rem;
  }

  .publication-title {
    font-size: 1rem;
  }

  .publication-year {
    font-size: 0.8rem;
    padding: 0.2rem 0.6rem;
  }

  .publication-org {
    font-size: 0.9rem;
  }

  .publication-desc {
    font-size: 0.9rem;
    line-height: 1.6;
  }

  .publication-link {
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
  }
}



/* Section underline consistency */
.tabs-content[data-tab="publications"] .achievement-underline {
  width: 60%;
  height: 2px;
  background: var(--primary, #007b83);
  margin: 1.5rem auto 0;
  border-radius: 2px;
}

/* When the left side is disabled/commented, expand & center the right side */
.contact-grid {
    display: flex;
    justify-content: center;
}

.contact-info-wrapper {
    max-width: 600px;
    width: 100%;
}


/* FIX: Give the left card a real height */
#contactCard {
    min-height: 350px;  /* Adjust as needed */
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Under construction box styling */
.uc-box {
    text-align: center;
    padding: 2rem 1.5rem;
    width: 100%;
}
/* Prevent any auto vertical shifting */
#contactCard,
.under-construction-card,
.uc-box {
    height: auto;
}

/* Make sure NO margin is pushing the right column downward */
.contact-info-header {
    margin-top: 0 !important;
}

/* -----------------------------
   Under Construction Styling
------------------------------ */
.uc-box {
    text-align: center;
    padding: 2rem 1.5rem;
}

.uc-icon {
    display: flex;
    justify-content: center;
    margin-bottom: 1.25rem;
}

.uc-gear {
    stroke: var(--primary, #007b83);
    animation: gearRotate 4s linear infinite,
               gearGlow 2.5s ease-in-out infinite alternate;
    width: 60px;
    height: 60px;
}

@keyframes gearRotate {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

@keyframes gearGlow {
    from { filter: drop-shadow(0 0 2px rgba(0, 150, 150, 0.3)); }
    to   { filter: drop-shadow(0 0 8px rgba(0, 150, 150, 0.6)); }
}

.uc-text {
    color: var(--muted);
    margin: 1rem 0 1.5rem;
    line-height: 1.6;
}

.uc-pulse {
    font-weight: 600;
    color: var(--primary);
    animation: pulse 1.4s ease-in-out infinite;
}

@keyframes pulse {
    0% { opacity: 0.4; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.05); }
    100% { opacity: 0.4; transform: scale(1); }
}

/* MOBILE RESPONSIVE */
@media (max-width: 768px) {
    .contact-grid {
        grid-template-columns: 1fr; /* Stack vertically */
    }
}

.expertise-description p {
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.expertise-description p:last-child {
    margin-bottom: 0;
}

/* Back to Top - minimalist, text-only */
.back-to-top {
  position: fixed;
  right: 1.25rem;
  bottom: 2.25rem;
  padding: 0;                  /* no outer ring */
  border-radius: 9999px;
  border: none;
  background: transparent;     /* remove ring */
  box-shadow: none;
  cursor: pointer;
  opacity: 0;
  transform: translateY(16px);
  pointer-events: none;
  transition: opacity 220ms ease, transform 240ms cubic-bezier(.2,.9,.2,1);
  z-index: 1500;
}

.back-to-top.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* Actual clickable pill */
.btt-inner {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  background: var(--white);
  padding: 0.55rem 0.9rem;
  border-radius: 9999px;
  box-shadow: 0 4px 12px rgba(11,17,34,0.12);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  white-space: nowrap;
  transition: 
    background 160ms ease,
    color 160ms ease,
    box-shadow 160ms ease;
}

.btt-icon {
  font-size: 0.9rem;
  line-height: 1;
}

.btt-text {
  transform: translateY(0.5px);
  letter-spacing: 0.2px;
}

/* ✅ Hover: primary highlight ONLY */
.back-to-top:hover .btt-inner {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 6px 18px rgba(11,17,34,0.18);
}

/* Mobile spacing */
@media (max-width: 480px) {
  .back-to-top {
    right: 0.6rem;
    bottom: 1.5rem;
  }
}

/* Soft fade-in text */
.back-to-top .btt-text {
  opacity: 0;
  transition: opacity 180ms ease;
}

.back-to-top.visible .btt-text {
  opacity: 1;
}

/* ---------- Success Story Modal ----------- */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.55);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    padding: 1rem;
}

.modal-overlay.active {
    display: flex;
}

.modal-container {
    background: var(--white);
    width: 100%;
    max-width: 720px;
    padding: 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-xl);
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
}

.modal-company {
    color: var(--primary);
    margin-bottom: 1rem;
}

.modal-text p {
    margin-bottom: 1rem;
    line-height: 1.65;
    color: var(--muted);
}

/* Force success story narrative flow */
.story-content {
  display: flex;
  flex-direction: column;
}

.story-content > .story-title        { order: 1; }
.story-content > .story-companies    { order: 2; }
.story-content > .highlighted-tags   { order: 3; }
.story-content > .story-summary      { order: 4; }
.story-content > .story-body         { order: 5; }
.story-content > .story-tags         { order: 6; }

/* Hide legacy paragraph styling interference */
.story-content p { margin: 0; }

.story-companies { font-size:.85rem; color:#555; margin-bottom:.4rem; }
.story-summary  { font-style:italic; margin:.4rem 0 .6rem; }
.story-body     { line-height:1.6; }

.story-companies {
  display: flex;
  align-items: flex-start;
  gap: 0.4rem;
  font-size: 0.85rem;
  color: var(--muted);
  white-space: nowrap; /* keeps label on one line */
}

.company-label {
  flex-shrink: 0;
  white-space: nowrap;
}

.company-names {
  white-space: normal;      /* allow wrapping */
  word-break: break-word;   /* break long names safely */
}

.expertise-details.hidden {
  display: none;
}