/* ==========================================
   AHMED'S PORTFOLIO — STYLE SYSTEM
   ========================================== */

/* ---- Reset & Base ---- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow: hidden;
  height: 100vh;
}

body {
  font-family: 'Poppins', sans-serif;
  background: radial-gradient(circle at var(--sun-x, 50%) var(--sun-y, 30%), var(--sun-glow-color, rgba(255, 255, 255, 0.05)) 0%, #000000 65%) no-repeat;
  background-attachment: fixed;
  color: #fff;
  overflow: hidden;
  height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
  color: inherit;
}

img {
  display: block;
  max-width: 100%;
}


/* ==========================================
   HERO SECTION
   ========================================== */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 600px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ---- Sky gradient background ---- */
.hero__sky {
  position: absolute;
  inset: -30px;
  background: #000000;
  z-index: 1;
  will-change: transform;
}

/* ==========================================
   FIXED BACKGROUND & SCROLLJACKING
   ========================================== */
.fixed-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.scroll-container {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

.section-frame {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

#hero.section-frame {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  z-index: 9999;
}

/* ---- Clouds layer (BEHIND mountain) ---- */
.hero__clouds {
  position: absolute;
  inset: -200px;
  z-index: 2;
  will-change: transform;
  pointer-events: none;
}

.cloud {
  position: absolute;
  opacity: 0.85;
  filter: brightness(1.1);
}

.cloud--main {
  width: 1400px;
  top: 14%;
  left: -10%;
  animation: cloudFloat 30s ease-in-out infinite;
}

@keyframes cloudFloat {
  0%, 100% { transform: translateX(0) translateY(0); }
  50% { transform: translateX(30px) translateY(-10px); }
}

/* ---- Mountain layer ---- */
.hero__mountains {
  position: absolute;
  bottom: -80px;
  left: -120px;
  right: -120px;
  z-index: 3;
  will-change: transform;
  pointer-events: none;
  display: flex;
  justify-content: center;
  align-items: flex-end;
}

.mountain-img {
  width: 100%;
  min-width: 1400px;
  height: auto;
  object-fit: cover;
  object-position: center bottom;
  display: block;
}

/* Dark gradient overlay at mountain base */
.hero__mountain-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 250px;
  background: linear-gradient(to top, #000000 20%, transparent);
  z-index: 4;
  pointer-events: none;
}

/* ==========================================
   FLUID SIMULATION CANVAS
   ========================================== */
#fluid-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 10000;
  pointer-events: auto;
}


/* ==========================================
   HEADER / NAV BAR
   ========================================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10005;
  padding: 20px 32px;
  background: transparent !important;
  backdrop-filter: none !important;
}

.header__nav {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 1920px;
  margin: 0 auto;
}

/* Logo */
.header__logo {
  flex-shrink: 0;
  width: 40px;
  height: 30px;
  margin-right: 6px;
  display: flex;
  align-items: center;
}

.header__logo svg {
  width: 100%;
  height: auto;
}

/* Nav items row */
.header__items {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Name brand link (no outline) */
.header__name-link {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.header__name-link:hover {
  opacity: 0.8;
  transform: translateY(-1px);
}

/* Pill buttons */
.header__pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 20px;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  transition: all 0.3s ease;
  background: transparent;
  backdrop-filter: blur(4px);
}

.header__pill:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
}

/* Services wrapper for dropdown */
.header__services-wrapper {
  position: relative;
}

.header__services-arrow {
  width: 10px;
  height: 6px;
  transition: transform 0.3s ease;
}

.header__services-wrapper:hover .header__services-arrow,
.header__services-wrapper.active .header__services-arrow {
  transform: rotate(180deg);
}

/* CTA "Let's Talk" */
.header__cta {
  margin-left: auto;
  padding: 10px 24px;
  border-radius: 30px;
  background: #d3377f;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(211, 55, 127, 0.4);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.header__social-link-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.5);
  transition: all 0.3s ease;
  background: transparent;
  backdrop-filter: blur(4px);
  color: #fff;
  margin-left: 2px;
  text-decoration: none;
}

.header__social-link-icon:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-1px);
}

.header__social-link-icon svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  display: block;
}

.header__cta:hover {
  background: #e04490;
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(211, 55, 127, 0.55);
}


/* ==========================================
   SERVICES DROPDOWN
   ========================================== */
.services-dropdown {
  position: absolute;
  top: calc(100% + 12px);
  left: 0;
  transform: translateY(8px);
  width: 280px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 200;
}

.services-dropdown.open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.services-dropdown__inner {
  background: #111111; /* Sleek charcoal background */
  padding: 12px;
  border-radius: 36px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
}

.services-dropdown__hover-pill {
  position: absolute;
  top: 12px;
  left: 12px;
  width: calc(100% - 24px);
  height: 50px;
  border-radius: 28px;
  border: 1.5px solid #fff;
  pointer-events: none;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
  opacity: 0;
  z-index: 1;
}

.services-dropdown__inner:hover .services-dropdown__hover-pill {
  opacity: 1;
}

.services-dropdown__item {
  display: block;
  padding: 14px 20px;
  border-radius: 28px;
  font-size: 16px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.6);
  transition: color 0.25s ease;
  position: relative;
  z-index: 2;
}

.services-dropdown__item--active {
  color: rgba(255, 255, 255, 1);
  font-weight: 600;
}

/* When the user hovers over the dropdown, the active item goes back to 60% */
.services-dropdown__inner:hover .services-dropdown__item--active {
  color: rgba(255, 255, 255, 0.6);
}

/* Whichever item the user is actively hovering over becomes 100% */
.services-dropdown__item:hover {
  color: rgba(255, 255, 255, 1) !important;
}


/* ==========================================
   CENTER CONTENT (LOGO + SLOGAN)
   ========================================== */
.hero__center {
  position: relative;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  margin-top: 20px;
  will-change: transform;
}

.hero__big-logo {
  width: 480px;
  height: 480px;
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0px 10px 30px rgba(0, 0, 0, 0.6));
  animation: logoEntrance 1.2s cubic-bezier(0.16, 1, 0.3, 1) both;
}

#logo-3d-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 1;
  pointer-events: none;
}

.hero__big-logo svg {
  width: 100%;
  height: auto;
}

@keyframes logoEntrance {
  0% {
    opacity: 0;
    transform: scale(0.8) translateY(30px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.hero__slogan {
  font-size: 28px;
  font-weight: 500;
  color: #fff;
  text-shadow: 7px 7px 15px rgba(0, 0, 0, 0.6);
  letter-spacing: 0.5px;
  animation: sloganEntrance 1.2s cubic-bezier(0.16, 1, 0.3, 1) 0.3s both;
}

@keyframes sloganEntrance {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}


/* ==========================================
   LOCATION & CLOCK
   ========================================== */
/* ==========================================
   LOCATION & CLOCK (IN BOTTOM FLOATING BAR)
   ========================================== */
.bottom-bar__clock {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.bottom-bar__clock-location {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 2px;
}

.bottom-bar__clock-pin {
  width: 12px;
  height: auto;
}

.bottom-bar__clock-city {
  font-size: 14px;
  font-weight: 700;
  opacity: 0.8;
}

.bottom-bar__clock-time {
  font-size: 38px;
  font-weight: 800;
  line-height: 1;
  text-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
  letter-spacing: 0.5px;
}

/* Info Icon & Tooltip Bar */
.bottom-bar__info-trigger {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  margin-left: 2px;
}

.info-icon {
  width: 13px;
  height: 13px;
  opacity: 0.5;
  transition: opacity 0.3s ease, transform 0.3s ease;
  stroke: #ffffff;
}

.bottom-bar__info-trigger:hover .info-icon {
  opacity: 1;
  transform: scale(1.15);
}

.info-tooltip-bar {
  position: absolute;
  bottom: calc(100% + 14px);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  width: 280px;
  background: rgba(10, 10, 10, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 12px 16px;
  border-radius: 16px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 400;
  line-height: 1.4;
  text-align: left;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.3s;
  z-index: 10000;
}

.info-tooltip-bar::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border-width: 6px;
  border-style: solid;
  border-color: rgba(10, 10, 10, 0.95) transparent transparent transparent;
}

.bottom-bar__info-trigger:hover .info-tooltip-bar {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}


/* ==========================================
   BOTTOM FLOATING BAR
   ========================================== */
.hero__bottom-bar {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10005;
  width: calc(100% - 64px);
  max-width: 1854px;
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px 0 12px;
  border-radius: 60px;
  background: linear-gradient(135deg, rgba(10, 10, 10, 0.6) 0%, rgba(20, 20, 20, 0.6) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  animation: barEntrance 1s cubic-bezier(0.16, 1, 0.3, 1) 0.6s both;
}

@keyframes barEntrance {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(40px);
  }
  100% {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

/* Profile section */
.bottom-bar__profile {
  display: flex;
  align-items: center;
  gap: 16px;
}

.bottom-bar__avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  border: 3px solid rgba(255, 255, 255, 0.2);
}

.bottom-bar__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.bottom-bar__welcome {
  display: flex;
  flex-direction: column;
}

.bottom-bar__welcome-title {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.3;
}

.bottom-bar__welcome-title--mobile {
  display: none;
}

/* Status section */
.bottom-bar__status {
  display: flex;
  align-items: center;
  gap: 12px;
}

.bottom-bar__status-icon {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  animation: statusSpin 6s linear infinite;
}

.bottom-bar__status-icon svg {
  width: 100%;
  height: 100%;
}

@keyframes statusSpin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.bottom-bar__status-text {
  display: flex;
  flex-direction: column;
}

.bottom-bar__status-title {
  font-size: 22px;
  font-weight: 700;
}

.bottom-bar__status-subtitle {
  font-size: 14px;
  font-weight: 400;
  opacity: 0.85;
}

/* Scroll section */
.bottom-bar__scroll {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.bottom-bar__scroll-text {
  font-size: 17px;
  font-weight: 700;
  text-shadow: 7px 7px 13px rgba(0, 0, 0, 0.5);
}

.bottom-bar__scroll-indicator {
  width: 22px;
  height: 36px;
  border-radius: 11px;
  border: 2px solid #fff;
  display: flex;
  justify-content: center;
  padding-top: 6px;
}

.bottom-bar__scroll-dot {
  width: 8px;
  height: 14px;
  border-radius: 4px;
  background: #fff;
  animation: scrollBounce 2s ease-in-out infinite;
}

@keyframes scrollBounce {
  0%, 100% {
    transform: translateY(0);
    opacity: 1;
  }
  50% {
    transform: translateY(8px);
    opacity: 0.4;
  }
}


/* ==========================================
   ENTRANCE ANIMATIONS
   ========================================== */
.header {
  animation: headerSlide 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes headerSlide {
  0% {
    opacity: 0;
    transform: translateY(-30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}


/* ==========================================
   RESPONSIVE
   ========================================== */
@media (max-width: 1280px) {
  /* Clock in bottom bar is sized dynamically */
}

@media (max-width: 1024px) {
  .header__pill:nth-child(2) {
    display: none;
  }

  .hero__big-logo {
    width: 360px;
    height: 360px;
  }

  .hero__slogan {
    font-size: 22px;
  }

  .bottom-bar__status {
    display: none;
  }

  .hero__bottom-bar {
    height: 90px;
    padding: 0 24px 0 10px;
  }

  .bottom-bar__avatar {
    width: 64px;
    height: 64px;
  }

  .bottom-bar__welcome-title {
    font-size: 18px;
  }

  .bottom-bar__welcome-title--desktop {
    display: none;
  }

  .bottom-bar__welcome-title--mobile {
    display: block;
  }

  .bottom-bar__clock-time {
    font-size: 32px;
  }
}

@media (max-width: 768px) {
  .header__nav {
    gap: 8px;
  }

  .header__pill {
    padding: 8px 16px;
    font-size: 12px;
  }

  .header__cta {
    padding: 8px 20px;
    font-size: 12px;
  }

  #nav-datetime, #nav-name {
    display: none;
  }

  .hero__big-logo {
    width: 280px;
    height: 280px;
  }

  .hero__slogan {
    font-size: 18px;
  }

  .hero__bottom-bar {
    width: calc(100% - 32px);
    height: 80px;
    border-radius: 40px;
    bottom: 16px;
  }

  .bottom-bar__welcome-title {
    font-size: 15px;
  }

  .bottom-bar__scroll-text {
    font-size: 14px;
  }

  .bottom-bar__clock-time {
    font-size: 26px;
  }

  .info-tooltip-bar {
    left: auto;
    right: -10px;
    transform: translateY(8px);
  }
  
  .info-tooltip-bar::after {
    left: auto;
    right: 18px;
    transform: none;
  }
  
  .bottom-bar__info-trigger:hover .info-tooltip-bar {
    transform: translateY(0);
  }
}

/* Responsive Header Button Icons/Text styling */
.header__btn-icon {
  display: inline-block;
  vertical-align: middle;
}
#nav-resume .header__btn-icon {
  margin-right: 4px;
}
#nav-contact .header__btn-icon {
  margin-right: 6px;
}
.header__btn-text--short {
  display: none;
}

@media (max-width: 480px) {
  .header {
    padding: 12px 16px;
  }

  .header__pill {
    padding: 6px 12px;
    font-size: 11px;
  }

  #nav-status {
    display: none;
  }

  .header__btn-text:not(.header__btn-text--short) {
    display: none;
  }

  .header__btn-text--short {
    display: inline !important;
  }

  #nav-contact .header__btn-icon {
    margin-right: 0;
  }

  #nav-resume .header__btn-icon {
    margin-right: 4px !important;
  }

  #nav-contact {
    padding: 0 !important;
    border-radius: 50% !important;
    width: 36px !important;
    height: 36px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  #nav-resume {
    padding: 6px 12px !important;
    border-radius: 30px !important;
    width: auto !important;
    height: auto !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
  }

  .hero__big-logo {
    width: 200px;
    height: 200px;
  }

  .hero__slogan {
    font-size: 16px;
  }

  .bottom-bar__avatar {
    width: 50px;
    height: 50px;
  }

  .bottom-bar__welcome-title {
    font-size: 13px;
  }

  .bottom-bar__scroll {
    display: none;
  }

  .bottom-bar__clock-time {
    font-size: 20px;
  }

  .bottom-bar__clock-city {
    font-size: 11px;
  }

  .bottom-bar__clock-pin {
    width: 9px;
  }
}


/* ==========================================
   RESPONSIVE — NEW SECTIONS
   ========================================== */
@media (max-width: 1024px) {
  .section__title {
    font-size: 36px;
  }

  .about__grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .about__photo-wrapper {
    max-width: 400px;
    margin: 0 auto;
  }

  .services__grid {
    grid-template-columns: 1fr;
  }

  .work__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .testimonials__grid {
    grid-template-columns: 1fr;
  }

  .contact__grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

@media (max-width: 768px) {
  .section {
    padding: 80px 0;
  }

  .section__container {
    padding: 0 24px;
  }

  .section__title {
    font-size: 30px;
  }

  .work__grid {
    grid-template-columns: 1fr;
  }

  .process__timeline::before {
    left: 20px;
  }

  .process__step-number {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }

  .process__step {
    gap: 20px;
  }

  .process__step-content h3 {
    font-size: 22px;
  }

  .footer__inner {
    flex-direction: column;
    gap: 24px;
    text-align: center;
  }

  .footer__links {
    gap: 20px;
  }
}

@media (max-width: 480px) {
  .section__title {
    font-size: 26px;
  }

  .service-card {
    padding: 28px;
  }
}


