/* ----------------------------------- */
/* GLOBAL STYLES                       */
/* ----------------------------------- */

@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Baloo+Paaji:wght@400;500;600;700&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&display=swap");

:root {
  --max-container-width: 1920px;
  --min-container-padding: 1rem;
  --max-container-padding: 10rem;
}

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

body {
  font-family: "Poppins", sans-serif;
  font-size: clamp(0.95rem, 2.5vw, 1.05rem);
}

html {
  scroll-behavior: smooth;
}

p {
  color: rgb(85, 85, 85);
  font-size: clamp(0.95rem, 2.5vw, 1.05rem);
  line-height: 1.6;
}

a,
.btn {
  transition: all 300ms ease;
}

/* ----------------------------------- */
/* NAVIGATION                          */
/* ----------------------------------- */

nav,
.nav-links {
  display: flex;
}

nav {
  justify-content: space-around;
  align-items: center;
  height: 17vh;
}

.nav-links {
  gap: 2rem;
  list-style: none;
  font-size: 1.5rem;
}

a {
  color: black;
  text-decoration: none;
}

a:hover {
  color: grey;
  text-decoration: underline;
  text-underline-offset: 1rem;
  text-decoration-color: rgb(181, 181, 181);
}

.logo {
  font-size: 2rem;
}

.logo:hover {
  cursor: default;
}

/* Hamburger Nav (Mobile) */
#hamburger-nav {
  display: none;
  z-index: 1000;
  position: relative;
}

.hamburger-menu {
  position: relative;
  display: inline-block;
  z-index: 1001;
}

.hamburger-icon {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 24px;
  width: 30px;
  cursor: pointer;
}

.hamburger-icon span {
  width: 100%;
  height: 2px;
  background-color: black;
  transition: all 0.3 ease-in-out;
}

.menu-links {
  position: absolute;
  top: 100%;
  right: 0;
  background-color: white;
  width: fit-content;
  max-height: 0;
  overflow: hidden;
  transition: all 0.3 ease-in-out;
  z-index: 1002;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.menu-links a {
  display: block;
  padding: 10px;
  text-align: center;
  font-size: 1.5rem;
  color: black;
}

.menu-links li {
  list-style: none;
}

.menu-links.open {
  max-height: 300px;
}

.hamburger-icon.open span:first-child {
  transform: rotate(45deg) translate(10px, 5px);
}
.hamburger-icon.open span:nth-child(2) {
  opacity: 0;
}
.hamburger-icon.open span:last-child {
  transform: rotate(-45deg) translate(10px, -5px);
}

/* ----------------------------------- */
/* SECTIONS GENERAL                    */
/* ----------------------------------- */

section {
  padding-top: 4vh;
  margin: 0 clamp(var(--min-container-padding), 8vw, var(--max-container-padding));
  min-height: fit-content;
  max-width: var(--max-container-width);
  margin-left: auto;
  margin-right: auto;
}

.title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  text-align: center;
  font-family: "Baloo Paaji", cursive;
  font-weight: 400;
  color: #47484b;
}

.section__text__p1 {
  text-align: center;
}

.section__text__p2 {
  font-size: clamp(1.1rem, 3.5vw, 1.75rem);
  margin-bottom: 1rem;
}

/* ----------------------------------- */
/* PROFILE SECTION                     */
/* ----------------------------------- */

#profile {
  display: flex;
  justify-content: center;
  gap: clamp(2rem, 5vw, 5rem);
  height: 80vh;
  flex-wrap: wrap;
  align-items: center;
}

/* Profile picture (smaller) */
#profile .section__pic-container {
  display: flex;
  height: clamp(200px, 30vw, 280px);
  width: clamp(200px, 30vw, 280px);
  min-height: 200px;
  max-height: 280px;
  min-width: 200px;
  max-width: 280px;
  margin: auto 0;
  border-radius: 50%;
  overflow: hidden;
}

#profile .section__pic-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.section__text {
  align-self: center;
  text-align: center;
}

#socials-container {
  display: flex;
  justify-content: center;
  margin-top: 1rem;
  gap: 1rem;
}

.icon {
  cursor: pointer;
  height: 2rem;
}
/* Buttons */
.btn-container {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn {
  font-weight: 600;
  padding: clamp(0.875rem, 2vw, 1rem);
  min-height: 44px;
  min-width: 8rem;
  width: auto;
  border-radius: 2rem;
  font-size: clamp(0.875rem, 2vw, 1rem);
}

.btn-color-1,
.btn-color-2 {
  border: rgb(53, 53, 53) 0.1rem solid;
}

.btn-color-1,
.btn-color-2:hover {
  background: rgb(53, 53, 53);
  color: white;
}

.btn-color-1:hover {
  background: rgb(0, 0, 0);
}

.btn-color-2 {
  background: none;
}
.btn-color-2:hover {
  border: rgb(255, 255, 255) 0.1rem solid;
}

/* ----------------------------------- */
/* ABOUT SECTION                       */
/* ----------------------------------- */

/* ABOUT SECTION */
#about {
  position: relative;
  margin-bottom: 0; /* no extra white space */
}

.section-container {
  display: flex;
  align-items: stretch; /* keep text and image aligned */
  gap: 4rem;
}

.about-details-container {
  flex: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* About picture (smaller) */
#about .section__pic-container {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  max-width: clamp(200px, 30vw, 280px);
  min-width: 200px;
  width: 100%;
  height: clamp(200px, 30vw, 280px);
  min-height: 200px;
  border-radius: 50%;
  overflow: hidden;
}

.about-pic {
  border-radius: 50%;
  object-fit: cover;
  width: 100%;
  height: 100%;
}

.text-container {
  max-width: 900px;
  text-align: left;
}

/* Arrow */
.arrow {
  position: absolute;
  right: clamp(-3rem, -5vw, -5rem);
  bottom: 2.5rem;
  display: none;
}

@media (min-width: 1200px) {
  .arrow {
    display: block;
  }
}

/* ----------------------------------- */
/* FACTS SECTION                       */
/* ----------------------------------- */

#facts {
  position: relative;
  padding: 4rem 2rem;
  margin-top: 0; /* tight below about */
  text-align: center;
}
/* Facts Section title */
#facts .title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-family: "Baloo Paaji", cursive;
  font-weight: 400;
  color: #47484b;
  margin-top: 0.5rem;
}

.facts-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(1rem, 2vw, 1.5rem);
  width: 100%;
  max-width: 900px;
  margin: 2rem auto 0;
}

@media (min-width: 768px) and (max-width: 1024px) {
  .facts-container {
    grid-template-columns: repeat(2, 1fr);
  }
}
.fact-card {
  perspective: 1000px;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.fact-card:hover {
  transform: scale(1.02);
}

.fact-card-inner {
  position: relative;
  width: 100%;
  height: 200px;
  text-align: center;
  transition: transform 0.8s;
  transform-style: preserve-3d;
}

.fact-card:hover .fact-card-inner {
  transform: rotateY(180deg);
}

.fact-card-front,
.fact-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 12px;
  backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 1rem;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  background: #fff;
}

/* Front face styling */
.fact-card-front {
  color: #444; /* dimmed color (between gray & black) */
}

.fact-card-front h3 {
  font-size: 1.1rem;         /* smaller than before */
  font-style: italic;        /* subtle, elegant italic */
  font-weight: 500;          /* lighter than bold */
  color: #444;               /* dimmed black/gray */
  margin-bottom: 0.3rem;
  letter-spacing: 0.5px;     /* slight spacing for elegance */
}

.fact-card-front p {
  font-size: 0.9rem;
  color: #666;               /* softer gray for subtitle */
}

.fact-card-back {
  transform: rotateY(180deg);
  color: #222;
  background: #f9f9f9;
  align-items: center;
  padding: 1.5rem;
  text-align: center;
  font-family: 'Inter', sans-serif;
  font-weight: 300;
}

.card-title {
  font-weight: 600;
  display: block;
  margin-bottom: 0.6rem;
  font-size: 0.95rem;
  letter-spacing: 0.5px;
}

.card-body {
  font-style: italic;
  font-size: 0.85rem;
  color: #555;
  line-height: 1.6;
  display: block;
}

.fact-icon {
  height: 120px;
  width: auto;
}

/* ----------------------------------- */
/* EXPERIENCE SECTION                  */
/* ----------------------------------- */

#experience {
  position: relative;
}

.experience-sub-title {
  color: rgb(85, 85, 85);
  font-weight: 600;
  font-size: 1.75rem;
  margin-bottom: 2rem;
}

.experience-details-container {
  display: flex;
  justify-content: center;
  flex-direction: column;
}

.article-container {
  display: flex;
  flex-wrap: wrap;
  gap: 2.5rem;
  justify-content: space-around;
}

article {
  display: flex;
  width: 10rem;
  justify-content: space-around;
  gap: 0.5rem;
}

article .icon {
  cursor: default;
}

/* Slide 2 */
.slide-heading {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  font-style: italic;
  text-decoration: underline;
  color: #222;
}

.challenge-text {
  text-align: left;
  max-width: 700px;
  margin: 0 auto;
  line-height: 1.6;
  font-size: 1.05rem;
  color: #444;
}

.challenge-text .highlight {
  color: #000;
  font-weight: 600;
}
/* Slide 3 */
.work-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;   /* was 1.2rem – reduce space between items */
  text-align: left;
  max-width: 750px;
  margin: 0 auto;
}

.work-item {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;   /* smaller gap between bullet and text */
}

.work-item p {
  margin: 0;
  font-size: 1rem;     /* slightly smaller */
  color: #444;
  line-height: 1.4;    /* was 1.5 – tighter line spacing */
}

.work-icon {
  font-size: 1.5rem;
  min-width: 2rem;
}

.note {
  font-size: 0.9rem;
  color: #666;
  font-style: italic;
}

/* ----------------------------------- */
/* PROJECTS SECTION                    */
/* ----------------------------------- */

#projects {
  position: relative;
  padding: 4rem 2rem;
}

/* Projects Grid */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 3vw, 2rem);
  margin-top: 2rem;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

@media (min-width: 768px) and (max-width: 1024px) {
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Project Card */
.project-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.08);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid #f0f0f0;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0,0,0,0.12);
}

/* Project Image */
.project-img-container {
  width: 100%;
  height: 200px;
  overflow: hidden;
  position: relative;
}

.project-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
  aspect-ratio: 16 / 9;
}

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

/* Project Content */
.project-content {
  padding: 1.5rem;
}

.project-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: #232429;
  margin-bottom: 1rem;
  line-height: 1.3;
}

.project-description {
  color: #555;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

.project-description strong {
  color: #333;
  font-weight: 600;
}

/* Project Button Container */
.project-btn-container {
  display: flex;
  justify-content: center;
  margin-top: 1rem;
}

.project-btn {
  color: black;
  border-color: rgb(163, 163, 163);
  padding: 0.8rem 1.5rem;
  font-size: 0.9rem;
  min-width: 120px;
}

/* Idea Input Container */
.idea-input-container {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.idea-input {
  flex: 1;
  min-width: 200px;
  padding: clamp(0.75rem, 2vw, 0.8rem) 1rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: clamp(0.875rem, 2vw, 0.9rem);
  font-family: "Poppins", sans-serif;
  transition: border-color 0.3s ease;
  min-height: 44px;
}

.idea-input:focus {
  outline: none;
  border-color: #8B5CF6;
  box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.1);
}

.idea-submit-btn {
  padding: clamp(0.75rem, 2vw, 0.8rem) 1.2rem;
  font-size: clamp(0.875rem, 2vw, 0.9rem);
  white-space: nowrap;
  min-height: 44px;
}

/* Thank You Message */
.thank-you-message {
  color: #8B5CF6;
  font-weight: 600;
  text-align: center;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

/* Idea Form */
.idea-form {
  margin-top: 1rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .projects-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .idea-input-container {
    flex-direction: column;
  }
  
  .idea-submit-btn {
    width: 100%;
  }
}

/* ----------------------------------- */
/* CASE STUDIES SECTION                */
/* ----------------------------------- */

#case-studies {
  position: relative;
  padding: 4rem 2rem;
  text-align: center;
}

.case-studies-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
  margin-top: 2rem;
}

.case-study-card {
  background-color: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  padding: 1.5rem;
  max-width: 350px;
  flex: 1 1 300px;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: transform 0.2s ease-in-out;
}

.case-study-card:hover {
  transform: translateY(-5px);
}

.case-study-title {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.case-study-img {
  width: 100%;
  border-radius: 8px;
  object-fit: cover;
  margin-bottom: 1rem;
  aspect-ratio: 16 / 9;
  height: auto;
}

.case-study-text {
  font-size: 1rem;
  margin-bottom: 1.2rem;
  color: #555;
}

/* ----------------------------------- */
/* WORKIES SECTION                     */
/* ----------------------------------- */

.work-grid {
  display: flex;
  flex-direction: column;
  gap: 3rem;
  margin-top: 2rem;
}

.work-card {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  padding: 2rem;
  transition: box-shadow 0.3s ease;
}

.work-card:hover {
  box-shadow: 0 12px 28px rgba(0,0,0,0.12);
}

.work-card-header {
  display: flex;
  align-items: flex-start;
  gap: 2rem;
  margin-bottom: 1rem;
}

.work-slide {
  display: none;
  text-align: center;
  transition: opacity 0.6s ease;
}

.work-slide.active {
  display: block;
  opacity: 1;
}

.logo-img {
  border-radius: 8px;
  object-fit: contain;
  max-width: 100px;   /* was 180px */
  max-height: 80px;   /* add height limit */
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
}

.globstudy-logo {
  max-width: 200px;   /* much smaller */
  max-height: 160px;   /* keeps it balanced */
}


.slide-caption {
  font-size: 1rem;
  font-style: italic;
  color: #666;
}

.slide-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2rem;
  background: rgba(0,0,0,0.05);
  border: none;
  cursor: pointer;
  padding: 0.5rem 0.8rem;
  border-radius: 50%;
  transition: background 0.3s;
}

.slide-btn:hover {
  background: rgba(0,0,0,0.15);
}

.slide-btn.prev { left: 1rem; }
.slide-btn.next { right: 1rem; }

/* Work Content Layout - Only for first slide */
.work-slide.active .work-content {
  display: flex;
  align-items: center;
  gap: 2rem;
  height: 100%;
}

.work-logo-container {
  flex: 0 0 120px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 0.5rem;
}

.work-text-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 0;
  text-align: left;
}

.work-scope-summary {
  margin-top: 1rem;
  font-size: 0.95rem;
  color: #666;
  line-height: 1.6;
  font-style: italic;
}

.work-logo {
  max-width: 100%;
  height: auto;
  object-fit: contain;
  width: clamp(80px, 15vw, 120px);
  max-height: clamp(60px, 12vw, 160px);
}

/* New styles for updated Authme structure */
.org-line {
  font-size: 1.3rem;
  font-weight: 600;
  color: #222;
  margin-bottom: 1rem;
  line-height: 1.4;
}

.work-meta-line {
  margin: 0.5rem 0;
  font-size: 1rem;
  color: #555;
}

.work-meta-line .label {
  font-weight: 600;
  color: #333;
  margin-right: 0.5rem;
}

.impact-content {
  text-align: left;
  max-width: 700px;
  margin: 0 auto;
}

.impact-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0;
}

.impact-list li {
  margin: 1rem 0;
  padding: 0.8rem;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 4px solid #007bff;
  font-size: 1.05rem;
  line-height: 1.5;
  color: #444;
}

.impact-footer {
  margin-top: 2rem;
  text-align: center;
}

/* Work Accordion */
.work-accordion {
  margin-top: 1.5rem;
  border-top: 1px solid #e5e7eb;
  padding-top: 1.5rem;
}

.work-accordion summary {
  cursor: pointer;
  font-weight: 600;
  color: #4285F4;
  font-size: 1rem;
  padding: 0.75rem 1rem;
  background: #f8f9fa;
  border-radius: 8px;
  list-style: none;
  user-select: none;
  transition: background 0.2s ease;
}

.work-accordion summary::-webkit-details-marker {
  display: none;
}

.work-accordion summary::before {
  content: "▶ ";
  display: inline-block;
  margin-right: 0.5rem;
  transition: transform 0.2s ease;
}

.work-accordion[open] summary::before {
  transform: rotate(90deg);
}

.work-accordion summary:hover {
  background: #e9ecef;
}

.work-accordion-content {
  margin-top: 1.5rem;
  padding: 0 1rem;
  overflow-wrap: break-word;
  word-break: break-word;
  overflow-x: hidden;
}

.work-accordion-section {
  margin-bottom: 2rem;
}

.work-accordion-section:last-child {
  margin-bottom: 0;
}

.work-accordion-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: #333;
  margin-bottom: 0.75rem;
}

.work-accordion-section p {
  font-size: 0.95rem;
  line-height: 1.7;
  color: #555;
  margin: 0;
}

.work-bullet-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.work-bullet-list li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
  line-height: 1.7;
  color: #555;
}

.work-bullet-list li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: #4285F4;
  font-weight: bold;
  font-size: 1.2rem;
}

/* Responsive */
@media (max-width: 768px) {
  .work-card-header {
    flex-direction: column;
    text-align: center;
    gap: 1.5rem;
  }
  
  .work-logo-container {
    flex: 0 0 auto;
    margin: 0 auto;
  }
  
  .work-text-container {
    text-align: center;
  }
  
  .work-accordion-content {
    padding: 0;
    text-align: left;
  }
}


/* ----------------------------------- */
/* CONTACT & FOOTER                    */
/* ----------------------------------- */

#contact {
  display: flex;
  justify-content: center;
  flex-direction: column;
  height: 70vh;
}

.contact-info-upper-container {
  display: flex;
  justify-content: center;
  border-radius: 2rem;
  border: rgb(163, 163, 163) 0.1rem solid;
  margin: 2rem auto;
  padding: 0.5rem;
}

.contact-info-container {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 1rem;
}

.contact-info-container p {
  font-size: larger;
}

.contact-icon {
  cursor: default;
}

.email-icon {
  height: 2.5rem;
}

footer {
  height: 26vh;
  margin: 0 1rem;
}

footer p {
  text-align: center;
}

.brand-logo {
  height: clamp(60px, 8vw, 100px);
  width: auto;
  margin-top: 10px;
  cursor: pointer;
  max-height: 100px;
}

/* ----------------------------------- */
/* ANIMATIONS                          */
/* ----------------------------------- */

.section__text__p2 {
  display: inline-block;
  white-space: nowrap;
  overflow: hidden;
  border-right: .15em solid #333;
  font-size: clamp(1.1rem, 3.5vw, 1.75rem);
  animation: typing 8s steps(26, end) infinite, blink .8s infinite;
  max-width: 100%;
}

@keyframes typing {
  0% { width: 0; max-width: 100%; }
  35% { width: 100%; max-width: 100%; }
  65% { width: 100%; max-width: 100%; }
  100% { width: 0; max-width: 100%; }
}

@keyframes blink {
  from, to { border-color: transparent }
  50% { border-color: #333 }
}

@media (max-width: 600px) {
  .section__text__p2 {
    white-space: normal;
    animation: none;
    border-right: none;
  }
}
