@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap");

:root {
  --primary-color: #0e0905;
  --secondary-color: #c8893a;
  --secondary-color-dark: #9e6820;
  --text-dark: #1e1108;
  --text-light: #b09470;
  --white: #f5ede4;
  --max-width: 1200px;
}

* {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
}

.section__container {
  max-width: var(--max-width);
  margin: auto;
  padding: 5rem 1rem;
}

.section__title {
  font-size: 2rem;
  font-weight: 600;
  text-align: center;
}

.section__title span {
  color: var(--secondary-color);
}

.section__subtitle {
  font-size: 1rem;
  font-weight: 500;
  text-align: center;
}

img {
  width: 100%;
}

/* =========================
   NAVBAR
   ========================= */

/* NAVBAR - CLEAN TRANSPARENT */
nav {
  position: fixed;
  width: 100%;
  top: 0;
  left: 0;
  z-index: 1000;
  justify-content: center;
  /* transform: translateX(-50%);
  max-width: var(--max-width); */
  display: flex;
  padding: 1rem 0;
}

nav .nav__logo a {
  font-size: 1.5rem;
  font-weight: 600;
}

nav .nav__logo a span {
  color: var(--secondary-color);
}

.nav__container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(14, 9, 5, 0.7);
  backdrop-filter: blur(10px);
  padding: 0.8rem 1.5rem;
  border-radius: 12px;
  border: 1px solid rgba(200, 137, 58, 0.2);
}

.nav__logo a {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--white);
}

.nav__links {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}

.nav__links a {
  color: var(--text-light);
  font-weight: 500;
  transition: 0.3s;
  position: relative;
}

/* Hover effect */
.nav__links a:hover {
  color: var(--secondary-color);
}

/* Underline animation */
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0%;
  height: 2px;
  background: var(--secondary-color);
  transition: 0.3s;
}

.nav__links a:hover::after {
  width: 100%;
}

.blend-wrapper {
  width: 320px;
  height: 320px;
  border-radius: 50%;
  position: relative;
  display: grid;
  place-items: center;
  transform: perspective(800px) rotateX(5deg);
}

/* IMAGE (clean, no interference) */
.blend-wrapper img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  position: relative;
  z-index: 2;
}

/* 🔥 3D OUTER GLOW RING */
.blend-wrapper::before {
  content: "";
  position: absolute;
  inset: -25px;
  border-radius: 50%;

  background: conic-gradient(
    rgba(200,137,58,0) 45deg,
    rgba(200,137,58,0.9) 90deg,
    rgba(200,137,58,0) 180deg,
    rgba(200,137,58,0.9) 360deg
  );

  filter: blur(80px);
  animation: spin3D 6s linear infinite;
  z-index: 0;
}

/* ✨ SOFT DEPTH GLOW */
.blend-wrapper::after {
  content: "";
  position: absolute;
  inset: -40px;
  border-radius: 50%;

  background: radial-gradient(
    circle,
    rgba(200,137,58,0.25) 0%,
    rgba(200,137,58,0.08) 40%,
    transparent 70%
  );

  filter: blur(35px);
  z-index: 0;
}

/* ⚡ ANIMATION */
@keyframes spin3D {
  from {
    transform: rotate(0deg) scale(1);
  }
  to {
    transform: rotate(360deg) scale(1);
  }
}

/* FOR FOOTER */

.blend-wrapper-f {
  width: 420px;
  height: 420px;
  border-radius: 50%;
  overflow: hidden;
  position: relative;

  box-shadow:
    0 0 250px 4px rgba(200, 137, 58, 0.5),
    0 0 100px 10px rgba(200, 137, 58, 0.25),
    0 0 100px 20px rgba(14, 9, 5, 0.9);
}

.blend-wrapper-f::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  z-index: 1;
}

.blend-wrapper-f img {
  width: 100%;
  height: 100%;
  z-index: 2;
  position: relative;
  object-fit: cover;
  -webkit-mask-image: radial-gradient(circle,
    rgba(0,0,0,1) 55%,
    rgba(0,0,0,0.7) 70%,
    rgba(0,0,0,0.2) 85%,
    rgba(0,0,0,0) 100%
  );
  mask-image: radial-gradient(circle,
    rgba(0,0,0,1) 55%,
    rgba(0,0,0,0.7) 70%,
    rgba(0,0,0,0.2) 85%,
    rgba(0,0,0,0) 100%
  );
}

.blend-wrapper-f::after {
  content: "";
  position: absolute;
  inset: -40px; /* push far outside */
  border-radius: 50%;

  background: conic-gradient(
    transparent 0deg,
    rgba(200,137,58,0.9) 90deg,
    transparent 180deg,
    rgba(200,137,58,0.9) 270deg,
    transparent 360deg
  );

  filter: blur(30px);
  opacity: 0.9;
  animation: spinBlend 3s linear infinite;

  z-index: 0;
}

.btn {
  padding: 1rem;
  font-size: 0.9rem;
  font-weight: 600;
  outline: none;
  border: none;
  border-radius: 5px;
  color: var(--white);
  background-color: var(--secondary-color);
  cursor: pointer;
  transition: 0.3s;
}

.btn:hover {
  background-color: var(--secondary-color-dark);
}

a {
  text-decoration: none;
  color: var(--white);
}

body {
  color: var(--white);
  font-family: "Poppins", sans-serif;
}

/* =========================
   HEADER
   ========================= */
header {
  height: 100vh;
  /* background-image: url("assets/tmain.png"); */
  background-color: var(--primary-color);
  background-position: right right;
  background-repeat: no-repeat;
  background-size: cover;
}

.header__container {
  height: 100%;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.header__text {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}

.header__image {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}
.header__image .blend-wrapper {
  width: 520px;
  height: 520px;
}

.header__container p {
  color: var(--text-light);
  max-width: 400px;
  margin: 1rem 0;
}

.header__container p span {
  color: var(--white);
  padding: 0.5rem 1rem;
  background-color: var(--secondary-color);
  border-radius: 5px;
  margin-right: 1rem;
}

.header__container h1 {
  font-size: 3rem;
  line-height: 3rem;
}

.action__btns {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.action__btns .video {
  display: flex;
  align-items: center;
  gap: 1rem;
  cursor: pointer;
}

.action__btns .video .play {
  height: 50px;
  width: 50px;
  display: grid;
  place-content: center;
  font-size: 1.5rem;
  border-radius: 100%;
  background-color: var(--secondary-color);
  transition: 0.3s;
}

.action__btns .video span {
  font-size: 1rem;
  font-weight: 600;
}

.action__btns .video:hover .play {
  background-color: var(--secondary-color-dark);
}

/* =========================
   SECTIONS BG
   ========================= */
.about,
.project,
.service,
footer {
  background-color: var(--primary-color);
}

/* =========================
   ABOUT
   ========================= */
.about__container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.about__image,
.about__content {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.about__image img {
  max-width: 350px;
}

.about__details {
  padding: 2rem 0;
  color: var(--text-light);
  text-align: center;
}

/* =========================
   SERVICES (SKILLS)
   ========================= */
.service__grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1rem;
  margin-top: 5rem;
}

.service__card {
  display: grid;
  align-items: flex-start;
  gap: 1rem;
  padding: 2rem;
  background-color: var(--text-dark);
  border-radius: 5px;
}

.service__card i {
  font-size: 1.5rem;
}

.service__card h4 {
  font-size: 1.2rem;
  font-weight: 500;
}

.service__card p {
  color: var(--text-light);
}

.service__card .read__more {
  width: max-content;
  padding: 0.5rem 1rem;
  color: var(--text-light);
  font-size: 0.8rem;
  border-radius: 5px;
  background-color: rgba(200, 137, 58, 0.08);
  cursor: pointer;
}

/* =========================
   PROJECTS (MARQUEE BANNER)
   ========================= */

/* Banner container */
.project__marquee {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  padding: 20px 0;
  margin-top: 3rem;
}

/* Soft fade edges */
.project__marquee::before,
.project__marquee::after {
  content: "";
  position: absolute;
  top: 0;
  height: 100%;
  width: 90px;
  z-index: 2;
  pointer-events: none;
}

.project__marquee::before {
  left: 0;
  background: linear-gradient(to right, rgba(14, 9, 5, 1), transparent);
}

.project__marquee::after {
  right: 0;
  background: linear-gradient(to left, rgba(14, 9, 5, 1), transparent);
}

/* Moving track */
.project__track {
  display: flex;
  gap: 18px;
  width: max-content;
  animation: projectMarqueeMove 28s linear infinite;
}

/* Big project banner cards */
.project__bannerCard {
  min-width: 640px;
  max-width: 720px;
  height: 320px;
  border-radius: 22px;
  overflow: hidden;
  text-decoration: none;
  position: relative;
  border: 1px solid rgba(200, 137, 58, 0.2);
  background: rgba(200, 137, 58, 0.06);
  display: block;
  transform: translateZ(0);
}

/* Image */
.project__bannerCard img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: brightness(0.7);
  transition: transform 0.3s ease;
}

.project__bannerCard:hover img {
  transform: scale(1.06);
}

/* Hover glow */
.project__bannerCard:hover {
  border-color: rgba(200, 137, 58, 0.6);
  box-shadow: 0 12px 35px rgba(200, 137, 58, 0.15);
}

/* Text overlay */
.project__bannerText {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  padding: 16px 18px;
  border-radius: 18px;
  background: linear-gradient(
    to top,
    rgba(14, 9, 5, 0.92),
    rgba(14, 9, 5, 0.65)
  );
  border: 1px solid rgba(200, 137, 58, 0.2);
}

.project__bannerText h3 {
  margin: 0 0 6px;
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--white);
}

.project__bannerText p {
  margin: 0;
  font-size: 1rem;
  line-height: 1.4;
  color: rgba(245, 237, 228, 0.86);
}

/* Animation */
@keyframes projectMarqueeMove {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* =========================
   FOOTER
   ========================= */
.footer__container {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 2rem;
}

.footer__content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}

.footer__details {
  font-size: 0.8rem;
  color: var(--text-light);
  margin: 2rem 0;
  display: grid;
  gap: 1rem;
}

.social__icons {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.social__icons .icon {
  padding: 0.5rem;
  border-radius: 5px;
  color: var(--white);
  background-color: var(--secondary-color);
  transition: 0.3s;
  cursor: pointer;
}

.social__icons .icon:hover {
  background-color: var(--secondary-color-dark);
}

.footer__form {
  display: grid;
  gap: 1rem;
}

.footer__form :is(input, textarea) {
  padding: 1rem;
  background-color: var(--text-dark);
  outline: none;
  border: none;
  border-radius: 5px;
  color: var(--white);
}

.footer__form textarea {
  resize: none;
  font-family: "Poppins", sans-serif;
}

.footer__form button {
  width: max-content;
}

/* =========================
   MEDIA QUERIES
   ========================= */
@media (min-width: 640px) {
  .section__title {
    font-size: 2.5rem;
  }

  .header__container p {
    margin: 2rem 0;
  }

  .header__container h1 {
    font-size: 4rem;
    line-height: 4rem;
  }

  .action__btns {
    gap: 2rem;
  }

  .about__container {
    flex-direction: row;
  }

  .about__content {
    align-items: flex-start;
  }

  .about__details {
    text-align: left;
  }

  .service__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }

  .footer__container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 768px) {
  .header__container h1 {
    font-size: 5rem;
    line-height: 5rem;
  }

  .service__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* =========================
   PROJECT MARQUEE RESPONSIVE
   ========================= */
@media (max-width: 520px) {
  .project__bannerCard {
    min-width: 340px;
    height: 240px;
  }

  .project__bannerText h3 {
    font-size: 1.1rem;
  }

  .project__bannerText p {
    font-size: 0.9rem;
  }
}


/* ===== Marquee Buttons ===== */
.project__marqueeWrap {
  position: relative;
}

/* Hide horizontal scrollbar */
.project__marquee {
  scrollbar-width: none;
}
.project__marquee::-webkit-scrollbar {
  display: none;
}

.marqueeBtn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(200, 137, 58, 0.3);
  background: rgba(14, 9, 5, 0.75);
  color: var(--white);
  cursor: pointer;
  display: grid;
  place-items: center;
  font-size: 22px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.marqueeBtn:hover {
  background: rgba(14, 9, 5, 0.92);
  transform: translateY(-50%) scale(1.05);
}

.marqueeBtn--left { left: 10px; }
.marqueeBtn--right { right: 10px; }

/* Show buttons when hovering the marquee area */
.project__marqueeWrap:hover .marqueeBtn {
  opacity: 1;
  pointer-events: auto;
}

/* Mobile: always visible */
@media (max-width: 520px) {
  .marqueeBtn {
    opacity: 1;
    pointer-events: auto;
  }
}

@keyframes spinBlend {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}


/* =========================
   HEADER ENTRY + STAGGER
   ========================= */

/* Initial hidden state */
.header__text,
.header__image {
  opacity: 0;
}

/* Slide animations */
.animate-left {
  animation: slideInLeft 1s ease forwards;
}

.animate-right {
  animation: slideInRight 1s ease forwards;
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-80px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(80px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* =========================
   APPLE-STYLE TEXT REVEAL
   ========================= */

.reveal {
  opacity: 0;
  transform: translateY(30px);
}

/* Trigger stagger */
.header__text.animate-left .reveal {
  animation: fadeUp 0.8s ease forwards;
}

/* Stagger delays */
.header__text.animate-left .reveal:nth-child(1) { animation-delay: 0.2s; }
.header__text.animate-left .reveal:nth-child(2) { animation-delay: 0.4s; }
.header__text.animate-left .reveal:nth-child(3) { animation-delay: 0.6s; }
.header__text.animate-left .reveal:nth-child(4) { animation-delay: 0.8s; }
.header__text.animate-left .reveal:nth-child(5) { animation-delay: 1s; }

@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}


/* WORD BY WORD ANIMATION */

/* Typing cursor */
.typing-text {
  /* border-right: 2px solid var(--secondary-color); */
  white-space: normal;
  overflow: hidden;
}

/* Blinking cursor */
.typing-text.typing::after {
  content: "|";
  margin-left: 4px;
  animation: blink 5s infinite;
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

/* =========================
   MOBILE FIX (FINAL)
   ========================= */

@media (max-width: 768px) {

  /* Stack layout */
  .header__container {
    flex-direction: column;
    justify-content: center;
    text-align: center;
  }

  .header__text {
    align-items: center;
  }

  .header__image {
    width: 100%;
    margin-top: 2rem;
  }

  /* 🔥 FIX CIRCLE IMAGE OVERFLOW */
  .header__image .blend-wrapper {
    width: 70vw;          /* responsive size */
    max-width: 280px;     /* cap size */
    height: auto;
    aspect-ratio: 1/1;

    transform: none;      /* remove 3D tilt (causes overflow) */
  }

  /* 🔥 REMOVE HEAVY GLOW ON MOBILE */
  .blend-wrapper::before,
  .blend-wrapper::after {
    /* display: none; */
    display: block;
  inset: -10px;
  filter: blur(20px);
  }

  /* Prevent ANY horizontal scroll */
  html, body {
    overflow-x: hidden;
  }

}

/* =========================
   MOBILE ORDER FIX (IMAGE TOP)
   ========================= */

@media (max-width: 768px) {

  /* Keep column layout */
  .header__container {
    flex-direction: column;
  }

  /* 🔥 Change order */
  .header__image {
    order: -1;   /* move image to top */
  }

  .header__text {
    order: 1;    /* text below */
  }

}
/* =========================
   FOOTER MOBILE FIX
   ========================= */

@media (max-width: 768px) {

  /* Stack footer sections */
  .footer__container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer__content {
    align-items: center;
  }

  /* 🔥 Fix big circular image */
  .blend-wrapper-f {
    width: 70vw;
    max-width: 260px;
    height: auto;
    aspect-ratio: 1/1;

    margin: 0 auto;
  }

  /* Reduce heavy glow (prevents overflow) */
  .blend-wrapper-f::after {
    inset: -15px;
    filter: blur(15px);
  }

  /* Form full width */
  .footer__form {
    width: 100%;
  }

  .footer__form input,
  .footer__form textarea {
    width: 100%;
  }

  /* Center social icons */
  .social__icons {
    justify-content: center;
  }

  /* Prevent horizontal scroll completely */
  html, body {
    overflow-x: hidden;
  }
}