/* ===== KDC Client Portal Styles ===== */

/* Base text color fix for page */
.page-id-2757 .entry-content h1,
.page-id-2757 .entry-content h2,
.page-id-2757 .entry-content h3,
.page-id-2757 .entry-content h4,
.page-id-2757 .entry-content p,
.page-id-2757 .entry-content li,
.page-id-2757 .entry-content strong { color: #2c2c2c !important; }
.page-id-2757 .entry-content a { color: #d33f49 !important; }
.page-id-2757 .entry-content a:hover { color: #a02530 !important; }

/* === HERO === */
.kdc-portal-hero {
  background: linear-gradient(135deg, #3a2e3b 0%, #928793 100%);
  border-radius: 12px;
  padding: 56px 48px;
  margin-bottom: 32px;
  position: relative;
  overflow: hidden;
}
.kdc-portal-hero::before {
  content: '';
  position: absolute;
  top: -60px; right: -60px;
  width: 260px; height: 260px;
  border-radius: 50%;
  background: rgba(211,63,73,0.18);
}
.kdc-portal-hero::after {
  content: '';
  position: absolute;
  bottom: -80px; left: -40px;
  width: 320px; height: 320px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
}
.kdc-portal-hero-inner { position: relative; z-index: 1; }
.kdc-portal-badge {
  display: inline-block;
  background: rgba(211,63,73,0.9);
  color: #fff !important;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 16px;
  text-transform: uppercase;
}
.kdc-portal-title {
  color: #ffffff !important;
  font-size: 2.4rem;
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 14px 0 !important;
}
.kdc-portal-subtitle {
  color: rgba(255,255,255,0.9) !important;
  font-size: 1.05rem;
  line-height: 1.7;
  margin: 0 !important;
  max-width: 640px;
}

/* === CARDS GRID === */
.kdc-portal-cards {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 20px !important;
  margin-bottom: 32px !important;
}
.kdc-portal-card {
  border-radius: 10px;
  padding: 32px 28px;
  display: flex !important;
  flex-direction: column !important;
  gap: 10px;
}
.kdc-card-primary { background: #ffffff; border: 1px solid #e8e4e9; box-shadow: 0 4px 18px rgba(58,46,59,0.09); }
.kdc-card-secondary { background: #faf9fb; border: 1px solid #e8e4e9; box-shadow: 0 4px 18px rgba(58,46,59,0.05); }
.kdc-card-icon {
  width: 60px; height: 60px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 4px;
}
.kdc-card-primary .kdc-card-icon { background: rgba(211,63,73,0.1); color: #d33f49; }
.kdc-card-secondary .kdc-card-icon { background: rgba(146,135,147,0.12); color: #928793; }
.kdc-card-title { color: #2c2c2c !important; font-size: 1.2rem !important; font-weight: 700; margin: 0 !important; }
.kdc-card-text { color: #5c5660 !important; font-size: 0.95rem; line-height: 1.65; margin: 0 0 4px 0 !important; flex-grow: 1; }
a.kdc-portal-btn, a.kdc-portal-btn:link, a.kdc-portal-btn:visited {
  display: inline-block; background: #d33f49 !important;
  color: #ffffff !important; font-weight: 600; font-size: 0.9rem;
  padding: 11px 22px; border-radius: 6px; text-decoration: none !important;
  margin-top: 4px; align-self: flex-start;
}
a.kdc-portal-btn:hover, a.kdc-portal-btn:focus { background: #b83340 !important; color: #ffffff !important; }
.kdc-portal-btn-outline {
  display: inline-block; border: 2px solid #928793;
  color: #928793 !important; font-weight: 600; font-size: 0.9rem;
  padding: 9px 22px; border-radius: 6px; margin-top: 4px; align-self: flex-start;
}

/* === SECTIONS === */
.kdc-portal-section {
  background: #ffffff;
  border: 1px solid #e8e4e9;
  border-radius: 10px;
  padding: 36px 32px;
  margin-bottom: 24px;
  box-shadow: 0 2px 12px rgba(58,46,59,0.06);
}
.kdc-section-header { margin-bottom: 24px; }
.kdc-section-title {
  color: #2c2c2c !important;
  font-size: 1.35rem !important;
  font-weight: 700;
  margin: 0 0 6px 0 !important;
  padding-bottom: 10px;
  border-bottom: 3px solid #d33f49;
  display: inline-block;
}
.kdc-section-desc { color: #5c5660 !important; font-size: 0.95rem; margin: 10px 0 0 0 !important; }

/* === VIDEO PLACEHOLDER === */
.kdc-video-placeholder {
  background: #faf9fb; border: 2px dashed #d8d4da;
  border-radius: 8px; padding: 52px 24px; text-align: center;
}
.kdc-video-placeholder p { color: #928793 !important; margin: 12px 0 0 0; font-size: 0.95rem; line-height: 1.7; }

/* === TEMPLATES / RESOURCES GRID === */
.kdc-resources-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 20px;
}
.kdc-resource-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: #faf9fb;
  border: 1px solid #ede9ee;
  border-radius: 8px;
  padding: 18px 20px;
  transition: box-shadow 0.2s;
}
.kdc-resource-item:hover { box-shadow: 0 4px 14px rgba(58,46,59,0.1); }
.kdc-resource-icon { font-size: 1.6rem; flex-shrink: 0; margin-top: 2px; }
.kdc-resource-title { color: #2c2c2c !important; font-size: 0.95rem !important; font-weight: 700; margin: 0 0 4px 0 !important; }
.kdc-resource-desc { color: #6a6470 !important; font-size: 0.87rem; line-height: 1.55; margin: 0 !important; }
.kdc-resources-note { color: #5c5660 !important; font-size: 0.9rem; margin: 8px 0 0 0 !important; font-style: italic; }

/* === QUICK REFERENCE TIPS === */
.kdc-tips-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.kdc-tip-item {
  background: #faf9fb;
  border-left: 4px solid #d33f49;
  border-radius: 0 8px 8px 0;
  padding: 18px 20px;
}
.kdc-tip-icon { font-size: 1.5rem; margin-bottom: 8px; display: block; }
.kdc-tip-title { color: #2c2c2c !important; font-size: 0.95rem !important; font-weight: 700; margin: 0 0 6px 0 !important; }
.kdc-tip-text { color: #6a6470 !important; font-size: 0.87rem; line-height: 1.6; margin: 0 !important; }

/* === HELP BAR === */
.kdc-portal-help {
  background: #3a2e3b; border-radius: 8px; padding: 22px 32px; text-align: center; margin-top: 8px;
}
.kdc-portal-help p { color: #ffffff !important; margin: 0 !important; font-size: 1rem; }
.page-id-2757 .entry-content .kdc-portal-help p { color: #ffffff !important; }
.kdc-portal-help a, .page-id-2757 .entry-content .kdc-portal-help a { color: #f4a0a0 !important; font-weight: 600; text-decoration: none; }
.kdc-portal-help a:hover { text-decoration: underline; color: #ffffff !important; }

/* === RESPONSIVE === */
@media (max-width: 720px) {
  .kdc-portal-cards, .kdc-resources-grid, .kdc-tips-grid { grid-template-columns: 1fr !important; }
  .kdc-portal-title { font-size: 1.8rem !important; }
  .kdc-portal-hero { padding: 36px 24px; }
}

/* Egnyte featured resource card */
.page-id-2757 .entry-content .kdc-resource-featured {
  background: linear-gradient(135deg, #3a2e3b 0%, #5a4560 100%);
  border: 2px solid #928793;
  border-radius: 10px;
  grid-column: 1 / -1;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 20px;
}
.page-id-2757 .entry-content .kdc-resource-featured .kdc-resource-icon {
  font-size: 2.5rem;
  flex-shrink: 0;
}
.page-id-2757 .entry-content .kdc-resource-featured .kdc-resource-title {
  color: #ffffff !important;
  font-size: 1.15rem;
}
.page-id-2757 .entry-content .kdc-resource-featured .kdc-resource-desc {
  color: rgba(255,255,255,0.85) !important;
}


/* ===== APWC Training Video Page Styles ===== */

.apwc-wrap {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px 40px;
}

/* Hero */
.apwc-hero {
  background: linear-gradient(135deg, #3a2e3b 0%, #928793 100%);
  border-radius: 12px;
  padding: 50px 40px;
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
}
.apwc-hero::after {
  content: '';
  position: absolute;
  right: -60px;
  top: -60px;
  width: 250px;
  height: 250px;
  border-radius: 50%;
  background: rgba(211,63,73,0.15);
}
.apwc-badge {
  display: inline-block;
  background: #d33f49;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 16px;
}
.apwc-title {
  color: #ffffff !important;
  font-size: 2rem;
  font-weight: 700;
  margin: 0 0 12px;
  line-height: 1.2;
}
.apwc-subtitle {
  color: rgba(255,255,255,0.85) !important;
  font-size: 1rem;
  margin: 0;
  max-width: 600px;
}

/* Intro notice */
.apwc-intro {
  background: #fff8e1;
  border-left: 4px solid #d33f49;
  border-radius: 6px;
  padding: 14px 18px;
  margin-bottom: 32px;
  font-size: 0.9rem;
  color: #3a2e3b !important;
}
.apwc-intro p {
  margin: 0;
  color: #3a2e3b !important;
}

/* Video grid */
.apwc-video-grid {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.apwc-video-card {
  background: #ffffff;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  padding: 24px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.apwc-video-number {
  display: inline-block;
  background: #3a2e3b;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 12px;
  margin-bottom: 10px;
  letter-spacing: 1px;
}
.apwc-video-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: #3a2e3b !important;
  margin: 0 0 14px;
}
.apwc-video-embed {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: 8px;
  background: #000;
}
.apwc-video-embed iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 8px;
}

/* Help bar */
.apwc-help {
  background: #3a2e3b;
  border-radius: 10px;
  padding: 20px 28px;
  margin-top: 40px;
  text-align: center;
}
.apwc-help p {
  margin: 0;
  color: #ffffff !important;
  font-size: 0.95rem;
}
.apwc-help a {
  color: #f08080 !important;
}

/* ===== Main Portal: Locked APWC Section ===== */
.kdc-locked-section {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  padding: 28px;
  margin-bottom: 20px;
}
.kdc-locked-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}
.kdc-locked-badge {
  background: #3a2e3b;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 20px;
}
.kdc-locked-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #3a2e3b !important;
  margin: 0;
}
.kdc-locked-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}
.kdc-locked-video {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  background: #2a2a2a;
  aspect-ratio: 16/9;
}
.kdc-locked-video img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(3px) brightness(0.5);
  display: block;
}
.kdc-locked-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px;
  text-align: center;
}
.kdc-locked-icon {
  font-size: 1.4rem;
}
.kdc-locked-video-title {
  font-size: 0.7rem;
  color: rgba(255,255,255,0.9) !important;
  font-weight: 600;
  line-height: 1.3;
}
.kdc-locked-more {
  background: #f5f5f5;
  border-radius: 8px;
  aspect-ratio: 16/9;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  color: #928793 !important;
  font-weight: 600;
}
.kdc-locked-cta {
  background: #f9f9f9;
  border: 1px dashed #928793;
  border-radius: 8px;
  padding: 16px 20px;
  text-align: center;
}
.kdc-locked-cta p {
  margin: 0 0 10px;
  font-size: 0.9rem;
  color: #555 !important;
}
.kdc-locked-btn {
  display: inline-block;
  background: #d33f49;
  color: #ffffff !important;
  padding: 9px 22px;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none !important;
}
.kdc-locked-btn:hover {
  background: #b83540;
  color: #ffffff !important;
}

@media (max-width: 600px) {
  .kdc-locked-grid { grid-template-columns: 1fr; }
  .apwc-title { font-size: 1.5rem; }
}
a.kdc-locked-btn,
a.kdc-locked-btn:link,
a.kdc-locked-btn:visited {
  color: #ffffff !important;
  text-decoration: none !important;
}

/* ===== APWC Topic Index ===== */
.apwc-index {
  background: #ffffff;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  padding: 24px 28px;
  margin-bottom: 32px;
}
.apwc-index-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #3a2e3b !important;
  margin: 0 0 18px;
  padding-bottom: 12px;
  border-bottom: 2px solid #f0f0f0;
}
.apwc-index-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.apwc-index-cat-header {
  font-size: 0.85rem;
  font-weight: 700;
  color: #3a2e3b !important;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 2px solid #d33f49;
}
.apwc-index-list {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}
.apwc-index-list li {
  margin: 0 !important;
  padding: 2px 0 !important;
}
.apwc-index-list li::before {
  display: none !important;
}
.apwc-index-list a {
  font-size: 0.82rem;
  color: #555 !important;
  text-decoration: none !important;
  line-height: 1.6;
  display: block;
  padding: 2px 0;
  transition: color 0.15s;
}
.apwc-index-list a:hover {
  color: #d33f49 !important;
  text-decoration: none !important;
}

/* ===== APWC Category Section Headers ===== */
.apwc-cat-section {
  margin-bottom: 40px;
}
.apwc-cat-header {
  display: flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #3a2e3b 0%, #5a4560 100%);
  border-radius: 8px;
  padding: 14px 20px;
  margin-bottom: 20px;
  position: sticky;
  top: 0;
  z-index: 10;
}
.apwc-cat-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
}
.apwc-cat-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff !important;
  margin: 0;
}

@media (max-width: 600px) {
  .apwc-index-grid { grid-template-columns: 1fr; }
}