/* PK Digital Professional Website Styles */

:root {
  --pk-red: #e11d48;
  --pk-red-dark: #be185d;
  --pk-red-light: #f43f5e;
  --pk-black: #000000;
  --pk-gray: #1f2937;
  --pk-gray-light: #374151;
  --pk-white: #ffffff;
  --pk-white-muted: rgba(255, 255, 255, 0.7);
  --pk-white-dim: rgba(255, 255, 255, 0.5);
}

/* Base Styles */
* {
  box-sizing: border-box;
}

body {
  font-family: 'Poppins', sans-serif;
  line-height: 1.6;
  scroll-behavior: smooth;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
}

/* Hero Background */
.hero-bg {
  background:
    radial-gradient(1200px 600px at 20% 0%, rgba(225,29,72,0.25), transparent 60%),
    radial-gradient(1000px 600px at 80% 100%, rgba(225,29,72,0.18), transparent 60%),
    linear-gradient(180deg, rgba(0,0,0,.85), rgba(0,0,0,.9)),
    linear-gradient(135deg, #000000 0%, #1f2937 50%, #000000 100%);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-bg-light {
  background:
    radial-gradient(1200px 600px at 20% 0%, rgba(225,29,72,0.15), transparent 60%),
    radial-gradient(1000px 600px at 80% 100%, rgba(225,29,72,0.08), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,.85), rgba(255,255,255,.9)),
    linear-gradient(135deg, #ffffff 0%, #f8fafc 50%, #ffffff 100%);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* Animated Gradient */
@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.animated-gradient {
  background: linear-gradient(-45deg, #7f1d1d, #000000, #1f2937, #7f1d1d);
  background-size: 400% 400%;
  animation: gradientShift 14s ease infinite;
}

/* Typing Animation */
.typing-text {
  font-size: clamp(1.6rem, 4.2vw, 3rem);
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  border-right: .15em solid var(--pk-red);
  width: 0;
  opacity: 0;
  animation: 
    typing 6.2s steps(42, end) infinite,
    fadeEffect 6.2s ease-in-out infinite,
    blink-caret .75s step-end infinite;
}

@keyframes typing {
  0% { width: 0; opacity: 1; }
  60% { width: 100%; opacity: 1; }
  80% { width: 100%; opacity: 1; }
  90% { opacity: 1; }
  95% { opacity: 0; }
  100% { width: 0; opacity: 0; }
}

@keyframes fadeEffect {
  0%, 80% { opacity: 1; }
  90% { opacity: 1; }
  95%, 100% { opacity: 0; }
}

@keyframes blink-caret {
  from, to { border-color: transparent; }
  50% { border-color: var(--pk-red); }
}

/* Glass Effect */
.glass {
  background: linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0.02));
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,0.08);
}

.glass-dark {
  background: linear-gradient(180deg, rgba(0,0,0,0.06), rgba(0,0,0,0.02));
  backdrop-filter: blur(6px);
  border: 1px solid rgba(0,0,0,0.08);
}

/* PK Border */
.pk-border {
  border-image: linear-gradient(45deg, rgba(225,29,72,.6), rgba(255,255,255,.08)) 1;
  border-width: 1px;
  border-style: solid;
}

/* Link Underline Effect */
.link-underline {
  position: relative;
  text-decoration: none;
  transition: color 0.3s ease;
}

.link-underline::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0;
  height: 2px;
  background: var(--pk-red);
  transition: width 0.25s ease;
}

.link-underline:hover::after {
  width: 100%;
}

.link-underline.active {
  color: var(--pk-red);
  font-weight: 600;
}

.link-underline.active::after {
  width: 100%;
}

/* Button Styles */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  background: linear-gradient(135deg, var(--pk-red), var(--pk-red-dark));
  color: white;
  text-decoration: none;
  border-radius: 12px;
  font-weight: 600;
  font-size: 16px;
  transition: all 0.3s ease;
  border: 1px solid transparent;
  box-shadow: 0 4px 15px rgba(225, 29, 72, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--pk-red-dark), var(--pk-red));
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(225, 29, 72, 0.4);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  background: transparent;
  color: white;
  text-decoration: none;
  border-radius: 12px;
  font-weight: 600;
  font-size: 16px;
  transition: all 0.3s ease;
  border: 2px solid var(--pk-red);
}

.btn-secondary:hover {
  background: var(--pk-red);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(225, 29, 72, 0.3);
}

/* Card Hover Effects */
.card-hover {
  transition: all 0.3s ease;
}

.card-hover:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* Image Hover Effects */
.image-hover {
  transition: transform 0.5s ease;
  overflow: hidden;
}

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

/* Loading Animation */
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.animate-spin {
  animation: spin 1s linear infinite;
}

/* Responsive Container System */
.container-responsive {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: 4%;
  padding-right: 4%;
}

@media (min-width: 640px) {
  .container-responsive {
    padding-left: 6%;
    padding-right: 6%;
  }
}

@media (min-width: 1024px) {
  .container-responsive {
    padding-left: 8%;
    padding-right: 8%;
  }
}

@media (min-width: 1280px) {
  .container-responsive {
    padding-left: 10%;
    padding-right: 10%;
  }
}

@media (min-width: 1536px) {
  .container-responsive {
    padding-left: 12%;
    padding-right: 12%;
  }
}

/* Enhanced Responsive Design */
@media (max-width: 640px) {
  .container-responsive {
    padding-left: 4%;
    padding-right: 4%;
  }
  
  .responsive-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .portfolio-image {
    border-radius: 0.75rem;
  }
}

@media (max-width: 768px) {
  .typing-text {
    font-size: clamp(1.2rem, 6vw, 2rem);
    white-space: nowrap;
    border-right: .15em solid var(--pk-red);
    width: 0;
    opacity: 0;
    animation: 
      typing 6.2s steps(42, end) infinite,
      fadeEffect 6.2s ease-in-out infinite,
      blink-caret .75s step-end infinite;
  }
  
  .hero-bg {
    height: 50vh !important;
  }
  
  .btn-primary,
  .btn-secondary {
    width: 100%;
    justify-content: center;
  }
  
  .container-responsive {
    padding-left: 5%;
    padding-right: 5%;
  }
  
  .responsive-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.25rem;
  }
  
  /* Mobile Gallery Stats */
  .inline-flex.items-center.gap-8 {
    flex-direction: column;
    gap: 1rem;
  }
  
  .inline-flex.items-center.gap-8 .w-px {
    display: none;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .responsive-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
  }
}

@media (min-width: 1025px) {
  .responsive-grid {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
  }
}

@media (min-width: 1280px) {
  .responsive-grid {
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2.5rem;
  }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
  background: var(--pk-red);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--pk-red-dark);
}

/* Focus States */
button:focus,
a:focus,
input:focus,
textarea:focus {
  outline: 2px solid var(--pk-red);
  outline-offset: 2px;
}

/* Form Styles */
input,
textarea {
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(0, 0, 0, 0.1);
  color: #1f2937;
  transition: all 0.3s ease;
}

input:focus,
textarea:focus {
  background: rgba(255, 255, 255, 0.9);
  border-color: var(--pk-red);
  box-shadow: 0 0 0 3px rgba(225, 29, 72, 0.1);
}

input::placeholder,
textarea::placeholder {
  color: rgba(0, 0, 0, 0.5);
}

/* Animation Classes */
.fade-in {
  animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.slide-up {
  animation: slideUp 0.6s ease-out;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Utility Classes */
.text-gradient {
  background: linear-gradient(135deg, var(--pk-red), var(--pk-red-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.border-gradient {
  border: 2px solid;
  border-image: linear-gradient(45deg, var(--pk-red), var(--pk-red-light)) 1;
}

/* Enhanced Responsive Grid */
.responsive-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

@media (min-width: 640px) {
  .responsive-grid {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
  }
}

@media (min-width: 1024px) {
  .responsive-grid {
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2.5rem;
  }
}

/* Enhanced Image Hover Effects */
.portfolio-image {
  position: relative;
  overflow: hidden;
  border-radius: 1rem;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  background: linear-gradient(135deg, rgba(0,0,0,0.1), rgba(0,0,0,0.05));
}

.portfolio-image:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 25px 50px rgba(225, 29, 72, 0.3);
}

.portfolio-image img {
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 0.75rem;
}

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

/* Service Card Styling */
.service-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between; /* Space between content and button */
  min-height: 320px; /* Ensure consistent minimum height */
}

/* Custom border radius for service cards */
.service-card-rounded {
  border-radius: 0 1.5rem 0 0; /* top-left: 0, top-right: 1.5rem, bottom-right: 0, bottom-left: 0 */
}

/* Professional Gallery Image Styling */
.gallery-image {
  background: linear-gradient(135deg, rgba(0,0,0,0.1), rgba(0,0,0,0.05));
  border-radius: 0.75rem;
  padding: 0.5rem;
  transition: all 0.3s ease;
}

.gallery-image:hover {
  background: linear-gradient(135deg, rgba(225, 29, 72, 0.1), rgba(225, 29, 72, 0.05));
}

/* Enhanced Glass Effect */
.glass-enhanced {
  background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

/* Enhanced Dark Glass Effect */
.glass-dark-enhanced {
  background: linear-gradient(135deg, rgba(0,0,0,0.1), rgba(0,0,0,0.05));
  backdrop-filter: blur(20px);
  border: 1px solid rgba(0,0,0,0.1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

/* Service Icon Styling */
.service-icon {
  filter: drop-shadow(0 4px 8px rgba(225, 29, 72, 0.3));
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  animation: slowJump 5s ease-in-out infinite;
}

/* Staggered animation delays for service icons */
.service-icon:nth-child(1) { animation-delay: 0s; }
.service-icon:nth-child(2) { animation-delay: 0.8s; }
.service-icon:nth-child(3) { animation-delay: 1.6s; }
.service-icon:nth-child(4) { animation-delay: 2.4s; }
.service-icon:nth-child(5) { animation-delay: 3.2s; }
.service-icon:nth-child(6) { animation-delay: 4.0s; }

.service-icon:hover {
  filter: drop-shadow(0 8px 16px rgba(225, 29, 72, 0.5));
  transform: scale(1.05);
  animation-play-state: paused;
}

/* Slow jumping animation for service icons (5s total: 2s wait + 3s jump) */
@keyframes slowJump {
  0%, 40%, 100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-12px);
  }
  70% {
    transform: translateY(-6px);
  }
}

/* Responsive Service Icons */
@media (max-width: 640px) {
  .service-icon {
    width: 3rem;
    height: 3rem;
  }
}

@media (min-width: 641px) and (max-width: 768px) {
  .service-icon {
    width: 4rem;
    height: 4rem;
  }
}

@media (min-width: 769px) {
  .service-icon {
    width: 5rem;
    height: 5rem;
  }
}

/* Mobile UX Utilities */
.scrollbar-hide {
  -ms-overflow-style: none;  /* Internet Explorer 10+ */
  scrollbar-width: none;  /* Firefox */
}
.scrollbar-hide::-webkit-scrollbar { 
  display: none;  /* Safari and Chrome */
}

/* Mobile Touch Interactions */
.active\:scale-95:active {
  transform: scale(0.95);
}

/* Image Loading States */
.image-skeleton {
  background: linear-gradient(90deg, #1a1a1a 25%, #2a2a2a 50%, #1a1a1a 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
}

@keyframes skeleton-loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.image-loading {
  position: relative;
  overflow: hidden;
}

.image-loading::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, #1a1a1a 25%, #2a2a2a 50%, #1a1a1a 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  z-index: 1;
}

.image-loaded {
  animation: image-fade-in 0.3s ease-in-out;
}

@keyframes image-fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Preload Critical Images */
.preload-images {
  position: absolute;
  width: 0;
  height: 0;
  visibility: hidden;
  pointer-events: none;
}

/* Lazy Loading */
.lazy-image {
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
}

.lazy-image.loaded {
  opacity: 1;
}

/* Intersection Observer Fallback */
.image-placeholder {
  background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 50%, #1a1a1a 100%);
  background-size: 200% 200%;
  animation: placeholder-shimmer 2s ease-in-out infinite;
}

@keyframes placeholder-shimmer {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

/* Floating Elements Animation */
.floating-elements {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: hidden;
}

.floating-svg {
  position: absolute;
  animation: float 20s ease-in-out infinite, slowJump 5s ease-in-out infinite;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

.floating-svg:hover {
  animation-play-state: paused;
  transform: scale(1.1);
}

/* Individual floating paths */
.floating-svg-1 {
  top: 15%;
  left: 10%;
  animation-delay: 0s, 0s;
  animation-duration: 25s, 5s;
}

.floating-svg-2 {
  top: 25%;
  right: 15%;
  animation-delay: -5s, 0.8s;
  animation-duration: 30s, 5s;
}

.floating-svg-3 {
  bottom: 30%;
  left: 8%;
  animation-delay: -10s, 1.6s;
  animation-duration: 22s, 5s;
}

.floating-svg-4 {
  top: 40%;
  right: 8%;
  animation-delay: -15s, 2.4s;
  animation-duration: 28s, 5s;
}

.floating-svg-5 {
  bottom: 20%;
  right: 25%;
  animation-delay: -7s, 3.2s;
  animation-duration: 26s, 5s;
}

.floating-svg-6 {
  top: 60%;
  left: 20%;
  animation-delay: -12s, 4.0s;
  animation-duration: 24s, 5s;
}

@keyframes float {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  25% {
    transform: translateY(-20px) rotate(5deg);
  }
  50% {
    transform: translateY(-10px) rotate(-3deg);
  }
  75% {
    transform: translateY(-25px) rotate(2deg);
  }
}

/* Geometric Particles */
.geometric-particle {
  position: absolute;
  animation: drift 15s ease-in-out infinite;
  pointer-events: none;
}

.particle-circle {
  background: linear-gradient(135deg, rgba(225, 29, 72, 0.3), rgba(244, 63, 94, 0.4));
  border-radius: 50%;
}

.particle-triangle {
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-bottom: 7px solid rgba(225, 29, 72, 0.4);
  background: none;
}

.particle-square {
  background: linear-gradient(135deg, rgba(225, 29, 72, 0.3), rgba(244, 63, 94, 0.4));
  border-radius: 2px;
}

.particle-1 {
  width: 6px;
  height: 6px;
  top: 20%;
  left: 30%;
  animation-delay: 0s;
  animation-duration: 18s;
}

.particle-2 {
  width: 4px;
  height: 4px;
  top: 70%;
  right: 40%;
  animation-delay: -6s;
  animation-duration: 22s;
}

.particle-3 {
  top: 35%;
  left: 15%;
  animation-delay: -12s;
  animation-duration: 16s;
}

.particle-4 {
  width: 5px;
  height: 5px;
  top: 50%;
  left: 70%;
  animation-delay: -9s;
  animation-duration: 20s;
}

.particle-5 {
  width: 7px;
  height: 7px;
  bottom: 25%;
  right: 15%;
  animation-delay: -15s;
  animation-duration: 24s;
}

.particle-6 {
  top: 15%;
  right: 30%;
  animation-delay: -3s;
  animation-duration: 21s;
}

.particle-7 {
  width: 6px;
  height: 6px;
  bottom: 50%;
  left: 25%;
  animation-delay: -18s;
  animation-duration: 19s;
}

@keyframes drift {
  0%, 100% {
    transform: translateX(0px) translateY(0px) scale(1);
    opacity: 0.4;
  }
  25% {
    transform: translateX(30px) translateY(-15px) scale(1.2);
    opacity: 0.6;
  }
  50% {
    transform: translateX(-20px) translateY(-30px) scale(0.8);
    opacity: 0.3;
  }
  75% {
    transform: translateX(40px) translateY(10px) scale(1.1);
    opacity: 0.5;
  }
}

/* Responsive floating elements */
@media (max-width: 768px) {
  .floating-svg-1 { left: 5%; top: 10%; }
  .floating-svg-2 { right: 5%; top: 20%; }
  .floating-svg-3 { left: 5%; bottom: 25%; }
  .floating-svg-4 { right: 5%; top: 35%; }
  .floating-svg-5 { right: 10%; bottom: 15%; }
  .floating-svg-6 { left: 15%; top: 55%; }

  .floating-svg img {
    width: 2rem !important;
    height: 2rem !important;
  }
}

/* Hide floating elements on very small screens for better performance and UX */
@media (max-width: 480px) {
  .floating-elements {
    display: none;
  }
}

/* Print Styles */
@media print {
  .no-print {
    display: none !important;
  }
}
