:root {
  --cn-navy: #0A2D64;
  --cn-navy-dark: #082653;
  --cn-teal: #1CA7A3;
  --cn-teal-dark: #147f7c;
  --cn-text: #1f2f46;
  --cn-muted: #667085;
  --cn-border: rgba(10, 45, 100, 0.10);
  --cn-border-strong: rgba(10, 45, 100, 0.16);
  --cn-shadow-soft: 0 8px 22px rgba(10, 45, 100, 0.06);
}

h2, p {
  color: #fff;
}

* {
  box-sizing: border-box;
}

.fa-pen, .fa-comment, .fa-pen-to-square, .fa-circle {
  color: #1CA7A3;
}
.fa-pen, .fa-plus, .fa-rectangle-list {
  font-size: 1rem;
}

.profile-page {
  width: 100%;
  padding: 1.25rem;
}

.profile-main {
  width: 100%;
  max-width: 980px;
  margin: 0 auto 2rem auto;
}

/* HERO */
.profile-hero-card {
  overflow: hidden;
  margin-bottom: 1rem;
  background: #fff;
  border: 1px solid var(--cn-border);
  border-radius: 28px;
  box-shadow: var(--cn-shadow-soft);
}

.profile-hero-bg {
  height: 118px;
  background:
    radial-gradient(circle at 88% 10%, rgba(255, 255, 255, 0.8), transparent 28%),
    linear-gradient(135deg, rgba(28, 167, 163, 0.22), rgba(10, 45, 100, 0.035));
}

.profile-hero-content {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 1.5rem;
  align-items: start;
  padding: 0 1.6rem 1.4rem;
  margin-top: -48px;
}

.profile-avatar-wrap {
  width: 118px;
  height: 118px;
  border-radius: 30px;
  background: #fff;
  padding: 5px;
  box-shadow: 0 14px 32px rgba(10, 45, 100, 0.14);
  position: relative;
}

.profile-avatar-edit-btn {
  position: absolute;
  right: -6px;
  bottom: -6px;
  width: 38px;
  height: 38px;
  border: 4px solid #fff;
  border-radius: 50%;
  background: var(--cn-navy);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: 0 10px 22px rgba(10, 45, 100, 0.18);
}

.profile-avatar-edit-btn i {
  font-size: 0.9rem;
  color: #fff;
}

.profile-avatar-edit-btn:hover {
  background: var(--cn-teal);
}

.profile-avatar-img,
.profile-avatar-fallback {
  width: 100%;
  height: 100%;
  border-radius: 25px;
  object-fit: cover;
}

.profile-avatar-fallback {
  background: linear-gradient(135deg, var(--cn-navy), var(--cn-teal));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: 900;
}

.profile-hero-copy {
  min-width: 0;
  padding-top: 3.65rem;
}

.profile-name-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.profile-name-row h1 {
  margin: 0;
  color: var(--cn-navy);
  font-size: clamp(1.8rem, 4vw, 2.35rem);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.055em;
}

.profile-credential-pill {
  padding: 0.38rem 0.72rem;
  border-radius: 999px;
  background: rgba(28, 167, 163, 0.11);
  color: var(--cn-teal-dark);
  font-size: 0.78rem;
  font-weight: 900;
}

.profile-role {
  margin: 0.45rem 0 0;
  color: var(--cn-text);
  font-size: 0.98rem;
  font-weight: 800;
}

.profile-username {
  margin: 0.35rem 0 0;
  color: var(--cn-muted);
  font-size: 0.88rem;
  font-weight: 700;
}

.profile-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1rem;
}

.profile-meta-row span {
  min-height: 32px;
  padding: 0 0.75rem;
  border-radius: 999px;
  background: #f4f7fb;
  color: var(--cn-navy);
  font-size: 0.8rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.profile-meta-row i {
  color: var(--cn-teal);
  font-size: 0.9rem;
}

.profile-edit-btn {
  margin-top: 3.65rem;
  align-self: start;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 42px;
  padding: 0 1rem;
  border-radius: 999px;
  background: var(--cn-navy);
  color: #fff;
  font-size: 0.86rem;
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 10px 22px rgba(10, 45, 100, 0.14);
  white-space: nowrap;
}

.profile-edit-btn:hover {
  background: var(--cn-navy-dark);
}

/* STATS */
.profile-stats-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--cn-border);
  background: #fbfcfe;
}

.profile-stat {
  padding: 0.95rem 1rem;
  text-align: center;
  border-right: 1px solid var(--cn-border);
}

.profile-stat:last-child {
  border-right: 0;
}

.profile-stat strong {
  display: block;
  color: var(--cn-navy);
  font-size: 1.05rem;
  font-weight: 900;
}

.profile-stat span {
  display: block;
  margin-top: 0.25rem;
  color: var(--cn-muted);
  font-size: 0.78rem;
  font-weight: 800;
}

/* OWNER ACTIONS */
.profile-owner-actions-card {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.profile-owner-action {
  min-height: 44px;
  padding: 0 1rem;
  border-radius: 16px;
  background: #fff;
  border: 1px solid var(--cn-border);
  color: var(--cn-navy);
  font-size: 0.88rem;
  font-weight: 900;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  box-shadow: 0 6px 16px rgba(10, 45, 100, 0.04);
}

.profile-owner-action i {
  color: var(--cn-teal);
}

.profile-owner-action:hover {
  border-color: rgba(28, 167, 163, 0.35);
}

/* GRID */
/* .profile-content-grid {
  display: grid;
  grid-template-columns: 0.95fr 1.25fr;
  gap: 1rem;
} */

.profile-info-card,
.profile-activity-card {
  background: #fff;
  border: 1px solid var(--cn-border);
  border-radius: 24px;
  padding: 1.25rem;
  box-shadow: var(--cn-shadow-soft);
}

/* CARD HEADERS */
.profile-card-header {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.profile-card-header i {
  color: var(--cn-teal);
}

.profile-card-header h2 {
  margin: 0;
  color: var(--cn-navy);
  font-size: 1rem;
  font-weight: 900;
}

/* ABOUT */
.profile-bio {
  margin: 1rem 0 1.25rem;
  color: var(--cn-text);
  font-size: 0.96rem;
  line-height: 1.75;
}

.profile-detail-list {
  display: grid;
  gap: 1rem;
}

.profile-detail-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.profile-detail-item i {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border-radius: 12px;
  background: rgba(28, 167, 163, 0.09);
  color: var(--cn-teal);
  display: flex;
  align-items: center;
  justify-content: center;
}

.profile-detail-item span {
  display: block;
  color: var(--cn-muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.profile-detail-item strong {
  display: block;
  margin-top: 0.15rem;
  color: var(--cn-navy);
  font-size: 0.92rem;
}

/* ACTIVITY */
.profile-activity-list {
  margin-top: 0.35rem;
}

.profile-activity-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 0.85rem;
  align-items: center;
  padding: 0.95rem 0;
  border-bottom: 1px solid var(--cn-border);
  text-decoration: none;
}

.profile-activity-item:last-child {
  border-bottom: 0;
}

.activity-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: rgba(28, 167, 163, 0.09);
  color: var(--cn-teal);
  display: flex;
  align-items: center;
  justify-content: center;
}

.activity-comment {
  background: #eef4ff;
  color: var(--cn-navy);
}

.activity-copy {
  min-width: 0;
}

.activity-copy p {
  margin: 0 0 0.2rem;
  color: var(--cn-muted);
  font-size: 0.8rem;
  font-weight: 700;
}

.activity-copy strong {
  display: block;
  color: var(--cn-navy);
  font-size: 0.92rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.activity-time {
  color: var(--cn-muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.profile-empty-state {
  margin-top: 1rem;
  padding: 1.5rem;
  border: 1px dashed var(--cn-border-strong);
  border-radius: 18px;
  color: var(--cn-muted);
  text-align: center;
  font-size: 0.92rem;
}

.profile-founding-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    background: #0A2D64;
    color: #fff;
    font-size: 0.85rem;
    font-weight: 700;
    white-space: nowrap;
}

.profile-founding-badge i {
    color: #F5B942;
}

.profile-founding-card {
    display: flex;
    gap: 1rem;
    padding: 1.25rem;
    margin: 2rem 0;
    border-radius: 18px;
    background: linear-gradient(135deg, #0A2D64, #123B7A);
    color: #fff;
    box-shadow: 0 14px 35px rgba(10, 45, 100, 0.18);
}

.profile-founding-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: rgba(255, 255, 255, 0.14);
    color: #F5B942;
    flex-shrink: 0;
    font-size: 1.4rem;
}

.profile-founding-card h2 {
    margin: 0 0 0.35rem;
    font-size: 1.15rem;
}

.profile-founding-card p {
    margin: 0 0 0.75rem;
    opacity: 0.92;
}

.profile-founding-card ul {
    margin: 0;
    padding-left: 1.1rem;
}

.profile-founding-card li {
    margin-bottom: 0.35rem;
}

/* RESPONSIVE */
@media (max-width: 1100px) {
  .left-sidebar {
    display: none;
  }

  .main-view-container {
    margin: 0;
  }
}

@media (max-width: 900px) {
  .profile-content-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {

  .profile-page {
    padding: 0.85rem;
  }

  .profile-main {
    max-width: 100%;
  }

  .profile-hero-card,
  .profile-info-card,
  .profile-activity-card {
    border-radius: 22px;
  }

  .profile-hero-bg {
    height: 92px;
  }

  .profile-hero-content {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
    gap: 0.85rem;
    padding: 0 1rem 1rem;
    margin-top: -42px;
  }

  .profile-avatar-wrap {
    width: 96px;
    height: 96px;
    border-radius: 24px;
  }
  .profile-avatar-edit-btn {
    width: 34px;
    height: 34px;
    border-width: 3px;
    right: -5px;
    bottom: -5px;
  }

  .profile-avatar-img,
  .profile-avatar-fallback {
    border-radius: 20px;
  }

  .profile-avatar-fallback {
    font-size: 1.55rem;
  }

  .profile-hero-copy {
    padding-top: 0;
  }

  .profile-name-row,
  .profile-meta-row {
    justify-content: center;
  }

  .profile-name-row h1 {
    font-size: 1.65rem;
  }

  .profile-role {
    font-size: 0.92rem;
  }

  .profile-edit-btn {
    width: 100%;
    justify-content: center;
    margin-top: 0;
  }

  .profile-stat {
    padding: 0.85rem 0.4rem;
  }

  .profile-stat strong {
    font-size: 0.98rem;
  }

  .profile-stat span {
    font-size: 0.72rem;
  }

  .profile-owner-actions-card {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
  }

  .profile-owner-action {
    justify-content: center;
    min-height: 48px;
  }

  .profile-info-card,
  .profile-activity-card {
    padding: 1rem;
  }

  .profile-bio {
    font-size: 0.93rem;
  }

  .profile-activity-item {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .activity-time {
    display: none;
  }
}

@media (max-width: 390px) {
  .profile-page {
    padding: 0.75rem;
  }

  .profile-owner-actions-card {
    grid-template-columns: 1fr;
  }

  .profile-name-row h1 {
    font-size: 1.55rem;
  }

  .profile-stat span {
    font-size: 0.74rem;
  }
}