/* ============================================================
   RECENT PROJECTS PAGE — FDC Studios
   Grid layout with WhatsApp lead capture modal
   ============================================================ */

/* ----- VARIABLES ----- */
:root {
  --gold: #C8794D;
  --gold-light: #d4942a;
  --gold-dark: #a06b15;
  --dark: #0D0D0D;
  --dark-2: #1a1a1a;
  --beige: #E8E1D8;
  --beige-light: #f7efe5;
  --light: #F8F6F3;
  --white: #fff;
  --text: #333333;
  --text-light: #737373;
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --gradient-gold: linear-gradient(135deg, #C8794D 0%, #e8a83a 50%, #C8794D 100%);
  --gradient-dark: linear-gradient(180deg, #0D0D0D 0%, #1a1a1a 100%);
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-md: 0 8px 30px rgba(0,0,0,0.12);
  --shadow-lg: 0 20px 60px rgba(0,0,0,0.15);
}

/* ----- HERO ----- */
.prj-hero {
  margin-top: 83px;
  padding: 80px 0 60px;
  background: var(--gradient-dark);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.prj-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(201,131,28,0.08) 0%, transparent 60%);
}
.prj-hero .container { position: relative; z-index: 1; }
.prj-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(201,131,28,0.15);
  border: 1px solid rgba(201,131,28,0.3);
  color: var(--gold-light);
  padding: 8px 20px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 20px;
}
.prj-hero h1 {
  font-family: "Cormorant Garamond", serif;
  font-size: 48px;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 12px;
}
.prj-hero h1 span {
  background: var(--gradient-gold);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.prj-hero p {
  color: rgba(255,255,255,0.6);
  font-size: 18px;
  max-width: 600px;
  margin: 0 auto;
}

/* ----- PROJECTS GRID ----- */
.prj-section {
  padding: 60px 0 80px;
  background: var(--beige);
}
.prj-section .container { max-width: 1400px; padding: 0 20px; }
.prj-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.prj-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  height: 420px;
  display: block;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  transition: all 0.4s ease;
}
.prj-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}
.prj-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}
.prj-card:hover .prj-card__img {
  transform: scale(1.08);
}
.prj-card__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.1) 50%, transparent 80%);
  z-index: 1;
  transition: all 0.4s;
}
.prj-card:hover .prj-card__overlay {
  background: linear-gradient(0deg, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0.05) 50%, transparent 80%);
}
.prj-card__shine::before {
  position: absolute;
  top: 0;
  left: -100%;
  z-index: 3;
  display: block;
  content: '';
  width: 50%;
  height: 100%;
  background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 100%);
  transform: skewX(-25deg);
  opacity: 0;
  transition: opacity 0.3s;
}
.prj-card__shine:hover::before {
  opacity: 0.7;
  animation: shine 0.95s;
}
@keyframes shine { 100% { left: 125%; } }
.prj-card__info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px 20px;
  z-index: 2;
  text-align: center;
}
.prj-card__info h3 {
  color: var(--white);
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 6px;
  line-height: 1.4;
}
.prj-card__info .style-tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.9);
  font-size: 12px;
  font-weight: 500;
  backdrop-filter: blur(4px);
}
.prj-card__view {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  z-index: 3;
  opacity: 0;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 999px;
  background: var(--gradient-gold);
  color: var(--white);
  font-size: 14px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  white-space: nowrap;
}
.prj-card:hover .prj-card__view {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

/* ----- WHATSAPP MODAL ----- */
.prj-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 9999;
  backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.prj-modal-overlay.active {
  display: flex;
}
.prj-modal {
  background: var(--white);
  border-radius: var(--radius-lg);
  max-width: 480px;
  width: 100%;
  padding: 36px;
  position: relative;
  box-shadow: var(--shadow-lg);
  animation: modalSlideUp 0.35s ease;
}
@keyframes modalSlideUp {
  from { opacity: 0; transform: translateY(30px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.prj-modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: var(--light);
  color: var(--text-light);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
}
.prj-modal__close:hover {
  background: #e74c3c;
  color: var(--white);
}
.prj-modal__icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(37, 211, 102, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-size: 28px;
  color: #25D366;
}
.prj-modal h3 {
  text-align: center;
  font-size: 20px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 4px;
}
.prj-modal .prj-modal__sub {
  text-align: center;
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 24px;
}
.prj-modal .prj-modal__preview {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  background: var(--light);
  border-radius: var(--radius-sm);
  margin-bottom: 20px;
}
.prj-modal .prj-modal__preview img {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
}
.prj-modal .prj-modal__preview p {
  font-size: 13px;
  color: var(--text);
  margin: 0;
  line-height: 1.4;
}
.prj-modal .prj-modal__preview p strong {
  display: block;
  font-weight: 600;
}
.prj-modal .form-group {
  margin-bottom: 14px;
}
.prj-modal .form-group label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--dark);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.prj-modal .form-group input {
  width: 100%;
  padding: 11px 14px;
  border: 2px solid #e0e0e0;
  border-radius: var(--radius-sm);
  font-size: 14px;
  transition: all 0.3s;
  box-sizing: border-box;
}
.prj-modal .form-group input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,131,28,0.08);
}
.prj-modal .form-group input.error {
  border-color: #e74c3c !important;
}
.prj-modal .form-error {
  font-size: 11px;
  color: #e74c3c;
  margin-top: 3px;
  display: none;
}
.prj-modal .form-group.has-error .form-error {
  display: block;
}
.prj-modal .btn-submit {
  width: 100%;
  padding: 13px;
  background: #25D366;
  color: var(--white);
  border: none;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.prj-modal .btn-submit:hover {
  background: #1da851;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(37, 211, 102, 0.35);
}
.prj-modal .btn-submit:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}
.prj-modal .btn-submit i {
  font-size: 18px;
}
.prj-modal__note {
  text-align: center;
  font-size: 11px;
  color: var(--text-light);
  margin-top: 12px;
}

/* ----- SUCCESS STATE ----- */
.prj-modal__success {
  text-align: center;
  padding: 10px 0;
}
.prj-modal__success-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 16px;
  animation: successPop 0.5s ease;
}
.prj-modal__success-icon svg {
  width: 100%;
  height: 100%;
}
.checkmark-circle {
  stroke-dasharray: 166;
  stroke-dashoffset: 166;
  animation: circleDraw 0.6s ease forwards 0.2s;
}
.checkmark-check {
  stroke-dasharray: 48;
  stroke-dashoffset: 48;
  animation: checkDraw 0.4s ease forwards 0.6s;
}
@keyframes circleDraw {
  to { stroke-dashoffset: 0; }
}
@keyframes checkDraw {
  to { stroke-dashoffset: 0; }
}
@keyframes successPop {
  0% { transform: scale(0); }
  60% { transform: scale(1.15); }
  100% { transform: scale(1); }
}
.prj-modal__success h4 {
  font-size: 22px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 8px;
}
.prj-modal__success h4 span {
  color: #25D366;
}
.prj-modal__success .success-msg {
  font-size: 14px;
  color: var(--text-light);
  line-height: 1.6;
  margin-bottom: 20px;
  max-width: 360px;
  margin-left: auto;
  margin-right: auto;
}
.countdown-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
}
.countdown-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ddd;
  transition: all 0.4s ease;
}
.countdown-dot.active {
  background: #25D366;
  transform: scale(1.2);
  box-shadow: 0 0 8px rgba(37, 211, 102, 0.4);
}
.prj-modal__success .success-hint {
  font-size: 12px;
  color: var(--text-muted, #B5B5B5);
  margin: 0;
}
.prj-modal__success .success-hint span {
  font-weight: 700;
  color: var(--text-light);
}

/* ----- RESPONSIVE ----- */
@media (max-width: 1200px) {
  .prj-grid { grid-template-columns: repeat(2, 1fr); }
  .prj-card { height: 380px; }
}
@media (max-width: 991px) {
  .prj-hero h1 { font-size: 36px; }
  .prj-hero { padding: 60px 0 40px; margin-top: 50px; }
}
@media (max-width: 767px) {
  .prj-grid { grid-template-columns: 1fr; gap: 18px; }
  .prj-card { height: 340px; }
  .prj-hero h1 { font-size: 28px; }
  .prj-hero { margin-top: 65px; padding: 40px 0 30px; }
  .prj-section { padding: 40px 0 60px; }
  .prj-modal { padding: 24px 20px; }
}
@media (max-width: 480px) {
  .prj-card { height: 280px; }
}
