/* =============================================
   S4C – Space for Change | Project 05 Dark Stylesheet
   ============================================= */

/* Page Wrapper - Transparent with Cabin Backdrop */
.p5-patent-wrapper {
  background-color: var(--black);
  background-image: linear-gradient(rgba(8, 8, 8, 0.94), rgba(8, 8, 8, 0.94)), url('../images/architecture_cabin.png');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  color: var(--white);
  padding: 60px 0;
  border-radius: 12px;
  box-shadow: 0 10px 50px rgba(0, 0, 0, 0.3);
  margin: 0 auto;
  max-width: 1300px;
  position: relative;
  overflow: hidden;
}

/* Floating Objects / Canvas Background (أجسام متحركة) */
.p5-canvas-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
  z-index: 1;
}

.p5-creative-canvas {
  position: absolute;
  width: 150px;
  height: 150px;
  border: 2px dashed rgba(245, 200, 0, 0.08);
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  animation: p5-morphShape 12s infinite alternate;
  top: 15%;
  left: 5%;
}

.p5-creative-canvas-2 {
  position: absolute;
  width: 200px;
  height: 200px;
  border: 1px solid rgba(245, 200, 0, 0.05);
  border-radius: 50%;
  animation: p5-morphShape2 18s infinite linear;
  bottom: 20%;
  right: 5%;
}

.p5-drawing-line {
  position: absolute;
  width: 1px;
  height: 400px;
  background: linear-gradient(to bottom, transparent, rgba(245, 200, 0, 0.15), transparent);
  top: 25%;
  left: 50%;
  transform: rotate(45deg);
  animation: p5-scanDiagonal 15s infinite linear;
}

.p5-floating-object {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  animation: p5-floatObj 20s infinite linear;
}

.p5-floating-object.yellow-tint {
  border-color: rgba(245, 200, 0, 0.06);
}

@keyframes p5-morphShape {
  0% { border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%; transform: rotate(0deg); }
  100% { border-radius: 70% 30% 30% 70% / 70% 70% 30% 30%; transform: rotate(180deg); }
}

@keyframes p5-morphShape2 {
  0% { transform: rotate(0deg) scale(0.9); }
  50% { transform: rotate(180deg) scale(1.1); }
  100% { transform: rotate(360deg) scale(0.9); }
}

@keyframes p5-scanDiagonal {
  0% { transform: translate(-40vw, -40vh) rotate(45deg); }
  100% { transform: translate(40vw, 40vh) rotate(45deg); }
}

@keyframes p5-floatObj {
  0% { transform: translateY(110vh) rotate(0deg); opacity: 0; }
  10% { opacity: 0.3; }
  90% { opacity: 0.3; }
  100% { transform: translateY(-10vh) rotate(360deg); opacity: 0; }
}

/* Document Box - Semi-Transparent */
.p5-document {
  padding: 40px;
  border: 1px solid rgba(245, 200, 0, 0.15);
  background-color: rgba(8, 8, 8, 0.75);
  backdrop-filter: blur(10px);
  margin: 0 20px;
  position: relative;
  z-index: 2;
  border-radius: 8px;
}

.p5-document::before {
  content: '';
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  bottom: 10px;
  border: 1px dashed rgba(245, 200, 0, 0.1);
  pointer-events: none;
  border-radius: 4px;
}

/* Typography alignment with standard pages */
.p5-serif {
  font-family: 'Playfair Display', serif;
}

.p5-gold-text {
  color: var(--yellow);
}

.p5-title-col {
  text-align: center;
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.p5-patent-number {
  font-size: 0.85rem;
  letter-spacing: 2px;
  color: var(--yellow);
  font-weight: 600;
  margin-bottom: 10px;
}

.p5-main-title {
  font-size: clamp(1.8rem, 4.5vw, 3rem) !important;
  font-weight: 800;
  color: var(--yellow);
  margin-bottom: 15px;
  line-height: 1.2;
}

.p5-intro-text {
  font-size: 1rem;
  color: var(--white-60);
  line-height: 1.8;
  max-width: 420px;
}

/* 1. Header & Branding Section */
.p5-header-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr 1fr;
  gap: 30px;
  border-bottom: 2px solid rgba(245, 200, 0, 0.2);
  padding-bottom: 30px;
  margin-bottom: 40px;
  align-items: stretch;
}

.p5-brand-col {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.p5-logo-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 15px;
}

.p5-logo-wrap img {
  height: 50px;
  width: 50px;
  object-fit: contain;
}

.p5-brand-name {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--white);
  line-height: 1.2;
}

.p5-brand-name span {
  display: block;
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--white-60);
}

.p5-slogan {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--yellow);
  margin-top: 10px;
  line-height: 1.3;
}

.p5-lenses-col {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.p5-lenses-box {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(245, 200, 0, 0.15);
  padding: 15px;
  border-radius: 8px;
}

.p5-lenses-title {
  font-size: 0.9rem;
  letter-spacing: 1.5px;
  font-weight: 800;
  color: var(--yellow);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.p5-lenses-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.p5-lenses-list li {
  font-size: 0.88rem;
  font-weight: 500;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--white-60);
}

.p5-lenses-list li span {
  display: inline-flex;
  width: 18px;
  height: 18px;
  background: var(--yellow);
  color: var(--black);
  border-radius: 50%;
  font-size: 0.7rem;
  align-items: center;
  justify-content: center;
  font-weight: bold;
}

/* 2. Design Categories Section */
.p5-categories-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 15px;
  margin-bottom: 50px;
}

.p5-category-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom: 4px solid var(--yellow);
  border-radius: 8px;
  overflow: hidden;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  cursor: pointer;
}

.p5-category-card:hover {
  transform: translateY(-5px);
  border-color: var(--yellow);
  box-shadow: 0 10px 20px rgba(245, 200, 0, 0.15);
}

.p5-category-img {
  height: 130px;
  overflow: hidden;
  position: relative;
  background: var(--black);
}

.p5-category-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  opacity: 0.85;
}

.p5-category-card:hover .p5-category-img img {
  transform: scale(1.1);
  opacity: 1;
}

.p5-category-info {
  padding: 12px 10px;
  text-align: center;
  flex-grow: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.p5-category-title {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: var(--white);
  text-transform: uppercase;
  line-height: 1.3;
  transition: var(--transition);
}

.p5-category-card:hover .p5-category-title {
  color: var(--yellow);
}

/* Section Divider */
.p5-section-divider {
  text-align: center;
  margin: 40px 0;
  position: relative;
}

.p5-section-divider span {
  background: var(--black);
  padding: 0 20px;
  color: var(--yellow);
  font-weight: 800;
  font-size: 0.9rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  position: relative;
  z-index: 2;
}

.p5-section-divider::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  z-index: 1;
}

/* 3. Core Pillars Section */
.p5-pillars-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr 1fr;
  gap: 30px;
  margin-bottom: 50px;
}

.p5-pillar-box {
  background: rgba(255, 255, 255, 0.01);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 25px;
  position: relative;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
  transition: var(--transition);
}

.p5-pillar-box:hover {
  border-color: rgba(245, 200, 0, 0.2);
}

.p5-pillar-icon {
  width: 50px;
  height: 50px;
  background: rgba(245, 200, 0, 0.06);
  border: 1px solid rgba(245, 200, 0, 0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 15px;
  color: var(--yellow);
}

.p5-pillar-box h3 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--yellow);
  margin-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 8px;
}

.p5-pillar-box blockquote {
  font-size: 0.92rem;
  color: var(--white-60);
  font-style: italic;
  margin-bottom: 15px;
  line-height: 1.5;
  border-left: 2px solid var(--yellow);
  padding-left: 10px;
}

.p5-checklist {
  list-style: none;
  padding: 0;
  margin: 0;
}

.p5-checklist li {
  font-size: 0.92rem;
  color: var(--white-60);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
}

.p5-checklist li::before {
  content: '✓';
  color: var(--yellow);
  font-weight: bold;
}

/* Research Mission Box */
.p5-mission-box {
  background: radial-gradient(circle at 90% 10%, rgba(245, 200, 0, 0.03) 0%, transparent 50%), rgba(255, 255, 255, 0.02);
  border-color: rgba(245, 200, 0, 0.25);
}

.p5-mission-text {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--white);
  font-style: italic;
}

.p5-maple-bg {
  position: absolute;
  bottom: 15px;
  right: 15px;
  opacity: 0.04;
  font-size: 5rem;
  pointer-events: none;
  color: var(--yellow);
}

/* 4. Client / Member Journey */
.p5-journey-row {
  display: grid;
  grid-template-columns: 1fr 15px 1fr 15px 1fr 15px 1fr;
  align-items: center;
  margin-bottom: 50px;
}

.p5-journey-card {
  background: rgba(255, 255, 255, 0.01);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: var(--transition);
}

.p5-journey-card:hover {
  border-color: var(--yellow);
  transform: translateY(-3px);
}

.p5-journey-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 8px;
}

.p5-journey-step {
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--yellow);
  letter-spacing: 1px;
}

.p5-journey-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--white);
  margin-top: 2px;
}

.p5-journey-icon {
  font-size: 1.3rem;
  color: var(--yellow);
}

.p5-journey-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.p5-journey-list li {
  font-size: 0.88rem;
  color: var(--white-60);
  margin-bottom: 6px;
  position: relative;
  padding-left: 12px;
}

.p5-journey-list li::before {
  content: '•';
  color: var(--yellow);
  position: absolute;
  left: 0;
}

.p5-journey-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--yellow);
  opacity: 0.3;
  font-size: 1.2rem;
  font-weight: bold;
}

/* 5. 8-Step Research Process */
.p5-process-container {
  overflow-x: auto;
  padding: 20px 0;
  margin-bottom: 50px;
}

.p5-process-wrapper {
  display: flex;
  min-width: 1000px;
  justify-content: space-between;
  position: relative;
}

.p5-process-line {
  position: absolute;
  top: 30px;
  left: 5%;
  right: 5%;
  height: 2px;
  background: repeating-linear-gradient(90deg, rgba(245, 200, 0, 0.15), rgba(245, 200, 0, 0.15) 4px, transparent 4px, transparent 8px);
  z-index: 1;
}

.p5-process-step {
  width: 110px;
  text-align: center;
  position: relative;
  z-index: 2;
  cursor: default;
}

.p5-process-circle {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--black);
  border: 3px solid rgba(245, 200, 0, 0.3);
  color: var(--yellow);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 1.2rem;
  margin: 0 auto 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
  transition: var(--transition);
}

.p5-process-step:hover .p5-process-circle {
  border-color: var(--yellow);
  background: var(--yellow);
  color: var(--black);
  transform: scale(1.1);
  box-shadow: 0 0 15px rgba(245, 200, 0, 0.35);
}

.p5-process-step-title {
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--white-60);
  text-transform: uppercase;
  line-height: 1.3;
  transition: var(--transition);
}

.p5-process-step:hover .p5-process-step-title {
  color: var(--white);
}

/* 6. Transformation & Results */
.p5-transformation-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 15px;
  margin-bottom: 50px;
}

.p5-trans-card {
  background: rgba(255, 255, 255, 0.01);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 18px 12px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  transition: var(--transition);
}

.p5-trans-card:hover {
  transform: translateY(-3px);
  border-color: var(--yellow);
  background: rgba(255, 255, 255, 0.02);
}

.p5-trans-icon {
  font-size: 1.6rem;
  margin-bottom: 8px;
  display: inline-block;
}

.p5-trans-title {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--yellow);
  text-transform: uppercase;
  margin-bottom: 6px;
  letter-spacing: 0.5px;
}

.p5-trans-body {
  font-size: 0.8rem;
  color: var(--white-60);
  line-height: 1.45;
}

/* 7. Services & Solutions */
.p5-services-flex {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-bottom: 50px;
}

.p5-service-badge {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--white);
  padding: 10px 20px;
  border-radius: 30px;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  transition: var(--transition);
  cursor: default;
}

.p5-service-badge:hover {
  background: var(--yellow);
  color: var(--black);
  border-color: var(--yellow);
  box-shadow: 0 0 15px rgba(245, 200, 0, 0.2);
}

/* 8. We Design / Invent For */
.p5-designfor-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 15px;
  margin-bottom: 50px;
}

.p5-designfor-card {
  border: 1px dashed rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  padding: 15px 10px;
  text-align: center;
  background: rgba(255, 255, 255, 0.01);
  transition: var(--transition);
}

.p5-designfor-card:hover {
  background: rgba(255, 255, 255, 0.02);
  border-style: solid;
  border-color: var(--yellow);
}

.p5-designfor-icon {
  font-size: 1.5rem;
  margin-bottom: 8px;
}

.p5-designfor-title {
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--white);
  text-transform: uppercase;
  line-height: 1.3;
}

.p5-designfor-card:hover .p5-designfor-title {
  color: var(--yellow);
}

/* 9. CTA & Footer Banner */
.p5-cta-banner {
  background: #000000;
  color: var(--white);
  border-radius: 12px;
  padding: 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 0 100px rgba(245, 200, 0, 0.05);
  border: 1px solid rgba(245, 200, 0, 0.15);
}

.p5-cta-title {
  font-size: clamp(1.5rem, 3.5vw, 2.2rem);
  font-weight: 800;
  letter-spacing: 4px;
  color: var(--white);
  margin-bottom: 8px;
}

.p5-cta-sub {
  font-size: 1rem;
  color: var(--white-60);
  margin-bottom: 25px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.6;
}

.p5-cta-btn {
  background: var(--yellow);
  color: var(--black);
  border: none;
  padding: 15px 35px;
  font-size: 0.85rem;
  font-weight: 800;
  border-radius: 30px;
  cursor: pointer;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: var(--transition);
  box-shadow: 0 4px 15px rgba(245, 200, 0, 0.25);
  display: inline-block;
}

.p5-cta-btn:hover {
  background: var(--yellow-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(245, 200, 0, 0.4);
}

.p5-footer-details {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1.2fr;
  gap: 30px;
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  align-items: center;
  text-align: left;
}

.p5-qr-col {
  display: flex;
  align-items: center;
  gap: 15px;
}

.p5-qr-code {
  background: #ffffff;
  padding: 6px;
  border-radius: 6px;
  width: 75px;
  height: 75px;
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.1);
}

.p5-qr-code svg {
  width: 100%;
  height: 100%;
}

.p5-qr-text {
  font-size: 0.75rem;
  color: var(--white-60);
  line-height: 1.4;
}

.p5-statement-col {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.p5-maple-icon {
  font-size: 1.8rem;
  color: var(--yellow);
}

.p5-closing-text {
  font-size: 0.88rem;
  font-style: italic;
  color: var(--white);
  line-height: 1.4;
}

.p5-links-col {
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

.p5-web-url {
  font-size: 1rem;
  font-weight: 700;
  color: var(--yellow);
  display: flex;
  align-items: center;
  gap: 8px;
}

.p5-socials-row {
  display: flex;
  gap: 10px;
}

.p5-socials-row a {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  transition: var(--transition);
}

.p5-socials-row a:hover {
  background: var(--yellow);
  color: var(--black);
}

.p5-barcode-wrap {
  margin-top: 15px;
  opacity: 0.85;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.p5-barcode-img {
  height: 35px;
  width: auto;
  object-fit: contain;
}

.p5-barcode-text {
  font-size: 0.65rem;
  letter-spacing: 2px;
  color: var(--white-30);
  margin-top: 2px;
}

/* Responsive Media Queries */
@media (max-width: 1200px) {
  .p5-categories-grid, .p5-designfor-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .p5-transformation-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 991px) {
  .p5-header-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .p5-title-col {
    border-left: none;
    border-right: none;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding: 20px 0;
  }
  .p5-pillars-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .p5-journey-row {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  .p5-journey-arrow {
    transform: rotate(90deg);
    margin: 5px 0;
  }
  .p5-footer-details {
    grid-template-columns: 1fr;
    gap: 20px;
    text-align: center;
  }
  .p5-qr-col {
    justify-content: center;
  }
  .p5-links-col {
    align-items: center;
    text-align: center;
  }
  .p5-barcode-wrap {
    align-items: center;
  }
}

@media (max-width: 768px) {
  .p5-categories-grid, .p5-designfor-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .p5-transformation-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .p5-document {
    padding: 20px 15px;
  }
  .p5-patent-wrapper {
    padding: 30px 0;
    margin: 20px auto;
  }
}

@media (max-width: 480px) {
  .p5-categories-grid, .p5-designfor-grid, .p5-transformation-grid {
    grid-template-columns: 1fr;
  }
  .p5-main-title {
    font-size: 1.8rem !important;
  }
  .p5-cta-banner {
    padding: 20px;
  }
  .p5-cta-title {
    font-size: 1.4rem;
  }
}
