/* =========================================
   TRIPCOOKING PROFILE - FULL CSS
   Version centre resserré + droite en 2 colonnes
========================================= */

:root{
  --tc-header-h: 72px;

  --tc-left-w: 310px;
  --tc-center-w: 820px;
  --tc-right-w: 520px;

  --tc-gap: 20px;
  --tc-page-pad: 18px;
  --tc-sticky-top: calc(var(--tc-header-h) + 18px);

  --tc-page-bg: #f5efff;
  --tc-page-bg-2: #fbf8ff;

  --tc-sidebar-bg: #f2ebff;
  --tc-sidebar-bg-2: #efe6ff;

  --tc-surface: rgba(255,255,255,.95);
  --tc-surface-solid: #ffffff;

  --tc-border: #e7dafb;
  --tc-border-2: #d8c5fb;
  --tc-border-soft: rgba(124, 58, 237, .09);

  --tc-primary: #8b5cf6;
  --tc-primary-2: #a855f7;
  --tc-primary-3: #7c3aed;

  --tc-text: #2f2546;
  --tc-text-soft: #76688f;
  --tc-text-fade: #9f93b8;

  --tc-shadow-soft: 0 10px 28px rgba(120, 84, 186, .06);
  --tc-shadow-card: 0 16px 36px rgba(120, 84, 186, .08);

  --tc-radius-2xl: 30px;
  --tc-radius-xl: 24px;
  --tc-radius-lg: 18px;
  --tc-radius-md: 14px;
}

/* =========================================
   BASE
========================================= */

html{
  scroll-behavior: smooth;
}

body{
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--tc-text);
  background:
    radial-gradient(circle at top left, rgba(170,130,255,.08), transparent 26%),
    linear-gradient(180deg, #f8f4ff 0%, #f3ecff 100%);
}

.tcProfilePage,
.tcProfilePage *,
.tcProfilePage *::before,
.tcProfilePage *::after{
  box-sizing: border-box;
}

.tcProfilePage{
  min-height: 100vh;
  padding: calc(var(--tc-header-h) + 18px) var(--tc-page-pad) 28px 0;
}

.tcProfilePage a{
  color: inherit;
  text-decoration: none;
}

.tcProfilePage img{
  display: block;
  max-width: 100%;
}

.tcProfilePage button,
.tcProfilePage input{
  font: inherit;
}

/* =========================================
   LAYOUT
========================================= */

.tcProfileLayout--mockup{
  width: 100%;
  display: grid;
  grid-template-columns: var(--tc-left-w) minmax(640px, var(--tc-center-w)) var(--tc-right-w);
  gap: var(--tc-gap);
  align-items: start;
  justify-content: start;
}

.tcProfileMain{
  min-width: 0;
  max-width: var(--tc-center-w);
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* =========================================
   LEFT SIDEBAR
========================================= */

.tcProfileSidebar--left{
  position: sticky;
  top: var(--tc-sticky-top);
  align-self: start;
  max-height: calc(100vh - var(--tc-sticky-top) - 14px);
  overflow: auto;
  margin-left: 0;
  padding: 0;
  border-top-right-radius: 30px;
  border-bottom-right-radius: 30px;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  background: linear-gradient(180deg, rgba(244,238,255,.96) 0%, rgba(239,230,255,.98) 100%);
  border: 1px solid var(--tc-border);
  border-left: 0;
  box-shadow: var(--tc-shadow-soft);
  scrollbar-width: thin;
}

.tcProfileSidebar--left::-webkit-scrollbar,
.tcProfileSidebar--right::-webkit-scrollbar{
  width: 8px;
}

.tcProfileSidebar--left::-webkit-scrollbar-thumb,
.tcProfileSidebar--right::-webkit-scrollbar-thumb{
  background: #dac8fb;
  border-radius: 999px;
}

.tcProfileSidebar--left > .tcCard{
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  overflow: visible;
  border-bottom: 1px solid var(--tc-border-soft);
}

.tcProfileSidebar--left > .tcCard:last-child{
  border-bottom: 0;
}

.tcProfileSidebar--left .tcCard__head{
  padding: 18px 20px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--tc-border-soft);
}

.tcProfileSidebar--left .tcCard__title{
  font-size: 15px;
  font-weight: 900;
  color: var(--tc-text);
}

.tcProfileSidebar--left .tcCard__link,
.tcProfileSidebar--left .tcCard__footLink a{
  font-size: 14px;
  font-weight: 800;
  color: var(--tc-primary-3);
}

.tcProfileSidebar--left .tcCard__footLink{
  padding: 14px 20px 18px;
  border-top: 1px solid var(--tc-border-soft);
}

/* =========================================
   RIGHT SIDEBAR
========================================= */

.tcProfileSidebar--right{
  position: sticky;
  top: var(--tc-sticky-top);
  align-self: start;
  max-height: calc(100vh - var(--tc-sticky-top) - 14px);
  overflow: auto;
  min-width: 0;
  padding-right: var(--tc-page-pad);
  scrollbar-width: thin;
}

.tcRightSplitSection{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  align-items: start;
}

.tcRightPanel{
  min-width: 0;
  height: fit-content;
}

/* =========================================
   GENERIC CARDS
========================================= */

.tcTopSearchCard,
.tcPublicationHeaderCard,
.tcFeedCard,
.tcProfileSidebar--right .tcCard{
  background: var(--tc-surface);
  backdrop-filter: blur(10px);
  border: 1px solid var(--tc-border);
  border-radius: var(--tc-radius-2xl);
  box-shadow: var(--tc-shadow-soft);
  overflow: hidden;
}

.tcCard__title{
  color: var(--tc-text);
}

/* =========================================
   BUTTONS
========================================= */

.tcBtn{
  border: 0;
  outline: 0;
  cursor: pointer;
  transition: .18s ease;
}

.tcBtn--primary{
  min-height: 42px;
  padding: 0 16px;
  border-radius: 15px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  background: linear-gradient(135deg, #b18cff 0%, #8b5cf6 55%, #7c3aed 100%);
  box-shadow: 0 10px 20px rgba(139,92,246,.22);
}

.tcBtn--primary:hover{
  transform: translateY(-1px);
}

.tcBtn--soft{
  min-height: 38px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid var(--tc-border);
  background: #faf7ff;
  color: var(--tc-primary-3);
  font-weight: 800;
}

.tcBtn--icon,
.tcDotsBtn{
  width: 40px;
  height: 40px;
  border-radius: 14px;
  border: 1px solid var(--tc-border);
  background: #faf7ff;
  color: var(--tc-primary-3);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 800;
  cursor: pointer;
}

.tcMiniBtn{
  min-height: 32px;
  padding: 0 13px;
  border-radius: 999px;
  border: 0;
  background: #efe7ff;
  color: var(--tc-primary-3);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

/* =========================================
   LEFT - INTRO
========================================= */

.tcProfileIntroCard{
  padding: 20px;
}

.tcProfileIntroCard__top{
  display: flex;
  align-items: center;
  gap: 14px;
}

.tcProfileIntroCard__top img{
  width: 66px;
  height: 66px;
  border-radius: 50%;
  object-fit: cover;
  background: #f6efff;
  border: 2px solid #dfcffb;
  flex: 0 0 66px;
}

.tcProfileIntroCard__identity h1{
  margin: 0 0 4px;
  font-size: 18px;
  line-height: 1.1;
  font-weight: 900;
  color: var(--tc-text);
}

.tcProfileIntroCard__identity span{
  display: block;
  font-size: 14px;
  color: var(--tc-text-soft);
  font-weight: 600;
}

.tcProfileIntroCard__actions{
  margin-top: 16px;
  display: flex;
  gap: 10px;
}

.tcProfileIntroCard__actions .tcBtn--primary{
  flex: 1;
}

/* =========================================
   LEFT - MENU
========================================= */

.tcLeftMenuCard{
  padding: 10px;
}

.tcSideNav{
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.tcSideNav__item{
  min-height: 52px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-radius: 16px;
  color: #574978;
  font-weight: 800;
  transition: .18s ease;
}

.tcSideNav__item:hover{
  background: rgba(255,255,255,.5);
  color: var(--tc-primary-3);
}

.tcSideNav__item.is-active{
  background: rgba(255,255,255,.82);
  border: 1px solid var(--tc-border-2);
  color: var(--tc-primary-3);
}

/* =========================================
   LEFT - FRIENDS
========================================= */

.tcFriendList{
  display: flex;
  flex-direction: column;
}

.tcFriendItem{
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-top: 1px solid var(--tc-border-soft);
}

.tcFriendItem:first-child{
  border-top: 0;
}

.tcFriendItem img{
  width: 46px;
  height: 46px;
  border-radius: 50%;
  object-fit: cover;
  background: #f6efff;
  border: 2px solid #dfcffb;
  flex: 0 0 46px;
}

.tcFriendItem > div{
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.tcFriendItem strong{
  font-size: 15px;
  line-height: 1.2;
  font-weight: 800;
  color: var(--tc-text);
}

.tcFriendItem span{
  font-size: 14px;
  color: var(--tc-text-soft);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tcFriendItem .tcMiniBtn{
  margin-left: auto;
}

/* =========================================
   TOP CARD - COMPACT
========================================= */

.tcTopSearchCard{
  padding: 20px 22px 16px;
}

.tcTopSearchCard__head h2{
  margin: 0 0 6px;
  font-size: clamp(26px, 2.2vw, 36px);
  line-height: 1.03;
  letter-spacing: -.03em;
  font-weight: 950;
  color: #392453;
}

.tcTopSearchCard__head p{
  margin: 0;
  color: var(--tc-text-soft);
  font-size: 14px;
  line-height: 1.4;
  font-weight: 600;
}

.tcTopSearchBar{
  margin-top: 16px;
}

.tcTopSearchBar input{
  width: 100%;
  height: 50px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid var(--tc-border-2);
  background: #fff;
  outline: none;
  color: var(--tc-text);
  font-size: 15px;
}

.tcTopSearchBar input::placeholder{
  color: #9e8fbc;
  font-weight: 600;
}

.tcTopSearchBar input:focus{
  border-color: #c9afff;
  box-shadow: 0 0 0 4px rgba(139,92,246,.08);
}

.tcTopSearchActions{
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

/* =========================================
   PUBLICATION HEADER
========================================= */

.tcPublicationHeaderCard__top{
  padding: 18px 20px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--tc-border-soft);
}

.tcPublicationHeaderCard__top h3{
  margin: 0;
  font-size: 18px;
  font-weight: 900;
  color: var(--tc-text);
}

.tcPublicationHeaderCard__actions{
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.tcPublicationTabs{
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.tcPublicationTabs button{
  position: relative;
  height: 52px;
  border: 0;
  background: transparent;
  color: var(--tc-text-soft);
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}

.tcPublicationTabs button.is-active{
  color: var(--tc-primary-3);
}

.tcPublicationTabs button.is-active::after{
  content: "";
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 0;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, #b08cff, #8b5cf6);
}

/* =========================================
   FEED
========================================= */

.tcFeedWrap{
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.tcFeedCard{
  box-shadow: var(--tc-shadow-card);
}

.tcFeedCard__head{
  padding: 14px 18px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tcFeedCard__author{
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.tcFeedCard__avatar{
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  background: #f6efff;
  border: 2px solid #dfcffb;
  flex: 0 0 44px;
}

.tcFeedCard__name{
  font-size: 15px;
  font-weight: 900;
  color: var(--tc-text);
}

.tcFeedCard__meta{
  margin-top: 4px;
  font-size: 13px;
  color: var(--tc-text-soft);
  font-weight: 600;
}

.tcFeedCard__menu{
  width: 38px;
  height: 38px;
  border-radius: 12px;
  border: 1px solid var(--tc-border);
  background: #faf7ff;
  color: var(--tc-primary-3);
  font-size: 18px;
  cursor: pointer;
}

.tcFeedCard__body{
  padding: 0 18px 18px;
}

.tcFeedCard__titleRow{
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.tcFeedCard__title{
  margin: 0;
  font-size: clamp(28px, 2.3vw, 42px);
  line-height: 1.02;
  letter-spacing: -.03em;
  font-weight: 950;
  color: #392453;
}

.tcFeedCard__rating{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  color: var(--tc-text-soft);
  font-weight: 800;
  font-size: 14px;
}

.tcStars{
  color: #f1be42;
  letter-spacing: 1px;
}

.tcFeedCard__media{
  display: block;
  overflow: hidden;
  border-radius: 22px;
  background: #f5eeff;
}

.tcFeedCard__media img{
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.tcFeedRecipeFooter{
  padding: 14px 4px 6px;
}

.tcFeedRecipeFooter h4{
  margin: 0 0 8px;
  font-size: 17px;
  font-weight: 900;
  color: var(--tc-text);
}

.tcFeedRecipeFooter__meta{
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 14px;
  color: var(--tc-text-soft);
  font-weight: 700;
}

.tcFeedCard__actions{
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.tcFeedCard__actions button{
  min-height: 42px;
  border-radius: 14px;
  border: 1px solid var(--tc-border);
  background: #faf7ff;
  color: var(--tc-primary-3);
  font-weight: 800;
  cursor: pointer;
}

.tcCommentPreview--inline{
  margin-top: 14px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid var(--tc-border-soft);
  background: #fcfaff;
}

.tcCommentPreview__head{
  display: flex;
  align-items: center;
  gap: 12px;
}

.tcCommentPreview__head img{
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  background: #f6efff;
  border: 2px solid #dfcffb;
}

.tcCommentPreview__head > div{
  flex: 1;
  min-width: 0;
}

.tcCommentPreview__head strong{
  display: block;
  font-size: 14px;
  font-weight: 800;
  color: var(--tc-text);
}

.tcCommentPreview__head span{
  display: block;
  margin-top: 2px;
  font-size: 12px;
  color: var(--tc-text-fade);
  font-weight: 600;
}

.tcCommentPreview__text{
  margin-top: 10px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--tc-text-soft);
}

/* =========================================
   RIGHT COLUMN PANELS
========================================= */
.tcActivityHub{
  background: rgba(255,255,255,.96);
  border: 1px solid #e7dafb;
  border-radius: 28px;
  box-shadow: 0 16px 36px rgba(120, 84, 186, .08);
  overflow: hidden;
}

.tcActivityHub__head{
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  padding: 22px 22px 18px;
}

.tcActivityHub__titleWrap h3{
  margin: 0 0 8px;
  font-size: 22px;
  line-height: 1.05;
  font-weight: 950;
  color: #41206e;
}

.tcActivityHub__titleWrap p{
  margin: 0;
  max-width: 420px;
  color: #786994;
  font-size: 15px;
  line-height: 1.45;
  font-weight: 600;
}

.tcActivityHub__actions{
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

/* tabs */
.tcActivityTabs{
  display: flex;
  gap: 0;
  margin: 0 22px 0;
  padding: 4px;
  background: #f5efff;
  border: 1px solid #e2d3fb;
  border-radius: 999px;
}

.tcActivityTabs__btn{
  flex: 1;
  min-height: 56px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #6f5d91;
  font-size: 15px;
  font-weight: 900;
  cursor: pointer;
  transition: .2s ease;
}

.tcActivityTabs__btn.is-active{
  background: linear-gradient(135deg, #a978ff 0%, #8b5cf6 55%, #7c3aed 100%);
  color: #fff;
  box-shadow: 0 10px 22px rgba(139,92,246,.22);
}

/* panels */
.tcActivityPanel{
  padding-top: 14px;
}

.tcActivityPanel[hidden]{
  display: none;
}

/* list */
.tcActivityList{
  display: flex;
  flex-direction: column;
}

.tcActivityItem{
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px 22px;
  border-top: 1px solid rgba(124, 58, 237, .08);
}

.tcActivityItem:first-child{
  border-top: 1px solid rgba(124, 58, 237, .08);
}

.tcActivityItem img{
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  background: #f6efff;
  border: 2px solid #dcc8fb;
  flex: 0 0 52px;
}

.tcActivityItem--online::after{
  content: "";
  position: absolute;
  left: 58px;
  top: 58px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #9ad96a;
  border: 2px solid #fff;
}

.tcActivityItem__body{
  min-width: 0;
  flex: 1;
}

.tcActivityItem__top{
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 4px;
}

.tcActivityItem__top strong{
  font-size: 15px;
  line-height: 1.2;
  font-weight: 900;
  color: #2f2546;
}

.tcActivityItem__top small{
  font-size: 12px;
  color: #9c90b6;
  font-weight: 800;
  white-space: nowrap;
}

.tcActivityItem p{
  margin: 0;
  font-size: 15px;
  line-height: 1.45;
  color: #736587;
}

.tcActivityItem p span{
  color: #4a2d81;
  font-weight: 900;
}

/* composer */
.tcActivityHub__composer{
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 18px 22px 22px;
  border-top: 1px solid rgba(124, 58, 237, .08);
}

.tcActivityHub__composer input{
  flex: 1;
  height: 52px;
  padding: 0 18px;
  border-radius: 18px;
  border: 1px solid #e1d1fb;
  background: #fbf8ff;
  color: #2f2546;
  outline: none;
  font-size: 15px;
}

.tcActivityHub__composer input::placeholder{
  color: #9f93b8;
  font-weight: 600;
}

.tcActivityHub__composer input:focus{
  border-color: #c8adff;
  box-shadow: 0 0 0 4px rgba(139,92,246,.08);
}

.tcActivityHub__send{
  width: 52px;
  min-width: 52px;
  padding: 0;
  border-radius: 18px;
}

/* =========================================
   EMPTY
========================================= */

.tcEmptyText{
  padding: 22px 18px;
  color: var(--tc-text-fade);
  font-weight: 700;
}

/* =========================================
   RESPONSIVE
========================================= */

@media (max-width: 1540px){
  :root{
    --tc-left-w: 290px;
    --tc-center-w: 760px;
    --tc-right-w: 500px;
  }
}

@media (max-width: 1380px){
  .tcProfileLayout--mockup{
    grid-template-columns: var(--tc-left-w) minmax(580px, 1fr) var(--tc-right-w);
  }

  .tcRightSplitSection{
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1220px){
  .tcProfileLayout--mockup{
    grid-template-columns: var(--tc-left-w) minmax(0, 1fr);
  }

  .tcProfileSidebar--right{
    position: static;
    max-height: none;
    overflow: visible;
  }

  .tcRightSplitSection{
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 920px){
  :root{
    --tc-header-h: 68px;
  }

  .tcProfilePage{
    padding: calc(var(--tc-header-h) + 14px) 14px 20px 0;
  }

  .tcProfileLayout--mockup{
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .tcProfileSidebar--left,
  .tcProfileSidebar--right{
    position: static;
    max-height: none;
    overflow: visible;
    border-radius: 0 24px 24px 0;
  }

  .tcProfileSidebar--right{
    padding-right: 14px;
    padding-left: 14px;
  }

  .tcRightSplitSection{
    grid-template-columns: 1fr;
  }

  .tcTopSearchCard{
    padding: 18px;
  }

  .tcTopSearchCard__head h2{
    font-size: 28px;
  }

  .tcTopSearchCard__head p{
    font-size: 14px;
  }

  .tcPublicationHeaderCard__top{
    flex-direction: column;
    align-items: stretch;
  }

  .tcPublicationHeaderCard__actions{
    width: 100%;
  }

  .tcPublicationHeaderCard__actions .tcBtn{
    flex: 1;
  }

  .tcFeedCard__titleRow{
    flex-direction: column;
    align-items: flex-start;
  }

  .tcFeedCard__title{
    font-size: 28px;
  }

  .tcFeedCard__actions{
    grid-template-columns: 1fr;
  }

  .tcTopSearchActions{
    flex-wrap: wrap;
  }
}