html{
  -webkit-text-size-adjust:100%;
  text-size-adjust:100%;
  scrollbar-width:thin;
  scrollbar-color:rgba(240,202,117,.52) rgba(36,48,33,.28);
}
:root{
  --bg:#33472e;
  --side:#243021;
  --panel:#3d5236;
  --panel2:#4f6847;
  --green:#5c7050;
  --green2:#7f9471;
  --sage:#a9c295;
  --cream:#ffffff;
  --muted:#c3d0bb;
  --line:rgba(169,194,149,.24);
}
body{
  overflow-x:hidden;
  background:
    radial-gradient(circle at 52% -12%,rgba(169,194,149,.18),transparent 32%),
    linear-gradient(180deg,#34482f 0%,#33472e 48%,#243021 100%)!important;
}
*{
  scrollbar-width:thin;
  scrollbar-color:rgba(240,202,117,.42) rgba(36,48,33,.22);
}
*::-webkit-scrollbar{
  width:8px;
  height:8px;
}
*::-webkit-scrollbar-track{
  background:rgba(36,48,33,.32);
  border-radius:999px;
}
*::-webkit-scrollbar-thumb{
  min-height:52px;
  border:2px solid rgba(36,48,33,.92);
  border-radius:999px;
  background:linear-gradient(180deg,rgba(240,202,117,.78),rgba(169,194,149,.58));
}
*::-webkit-scrollbar-thumb:hover{
  background:linear-gradient(180deg,rgba(240,202,117,.92),rgba(169,194,149,.76));
}
*::-webkit-scrollbar-corner{
  background:transparent;
}
textarea::-webkit-resizer{
  background:
    linear-gradient(135deg,transparent 0 52%,rgba(240,202,117,.42) 53% 58%,transparent 59%),
    rgba(36,48,33,.72);
}
img,video,iframe{
  max-width:100%;
}
button,input,select,textarea{
  min-width:0;
}
/* Controles de navegação: mantém alvo de toque confortável em todas as telas. */
.back,.icon{
  width:44px;
  height:44px;
  min-width:44px;
  min-height:44px;
  display:inline-grid;
  place-items:center;
}
.app,.workspace,.content-frame{
  background:#33472e!important;
}
.sidebar{
  background:rgba(36,48,33,.98)!important;
  border-right-color:rgba(169,194,149,.22)!important;
}
.app.menu-hidden .sidebar{
  flex:0 0 0!important;
  flex-basis:0!important;
  width:0!important;
  min-width:0!important;
  padding-left:0!important;
  padding-right:0!important;
  border-right:0!important;
  box-shadow:none!important;
}
.app.menu-hidden .sidebar>*{
  opacity:0!important;
  pointer-events:none!important;
}
.toolbar,.top{
  background:rgba(51,71,46,.92)!important;
  border-bottom-color:rgba(169,194,149,.22)!important;
}
.welcome,.wrap,.page{
  background:transparent!important;
}
.card,.post,.composer-card,.profile-card,.suggest,.modal-box,.community-dialog,.profile-modal,.followers-box,.publish-box,.story-box,.box,.brand-side,.mission-card,.activity-chat,.mission-participants,.side-card,.overview-card,.preview-card,.schedule-item,.hero-panel,.pillar,.phase,.task,.badge-card,.plan,.direct-message,.message-card{
  background:
    linear-gradient(145deg,rgba(61,82,54,.96),rgba(36,48,33,.96))!important;
  border-color:rgba(169,194,149,.25)!important;
  box-shadow:0 18px 48px rgba(12,18,10,.12);
}
.card:hover,.post:hover,.pillar:hover,.phase:hover,.schedule-item:hover{
  border-color:rgba(169,194,149,.42)!important;
}
.nav button:hover,.nav button.active{
  background:#5c7050!important;
  color:var(--gold2)!important;
}
.user,.icon,.tool-btn,.btn.secondary,.chip,.admin-pill,.field input,.field select,.field textarea,input,select,textarea,.chat-editor,.comment-input,.direct-input{
  background:#243021!important;
  border-color:rgba(169,194,149,.27)!important;
}
.field input:focus,.field select:focus,.field textarea:focus,input:focus,select:focus,textarea:focus,.chat-editor:focus{
  border-color:var(--gold2)!important;
  box-shadow:0 0 0 3px rgba(169,194,149,.14)!important;
}
.media,.m1,.m2,.m3,.preview-stage{
  background:
    radial-gradient(circle at 50% 0,rgba(169,194,149,.18),transparent 38%),
    linear-gradient(145deg,#5c7050,#243021 58%,#61443c)!important;
}
.story-inner,.avatar,.profile-photo,.date-box,.preview-date,.phase-dot,.pillar-icon{
  background:#5c7050!important;
  border-color:rgba(169,194,149,.38)!important;
}
.bottom{
  background:rgba(36,48,33,.97)!important;
  border-color:rgba(169,194,149,.24)!important;
}
.menu-toggle-handle{
  background:rgba(92,112,80,.72)!important;
  border-color:rgba(169,194,149,.24)!important;
}
.wrap{
  width:min(1680px,100%)!important;
  padding-inline:clamp(14px,2.1vw,34px)!important;
}
.title{
  font-size:clamp(30px,3.2vw,46px)!important;
  line-height:1.08!important;
}
.card,.post,.composer-card,.profile-card,.suggest{
  min-width:0;
}
.grid,.two,.three,.four,.community,.journey-hero,.mission-layout{
  min-width:0;
}
.btn,.tool-btn,.composer-actions button,.publish-actions button,.modal-actions button{
  min-height:40px;
}
.bottom{
  max-width:760px;
  margin-inline:auto;
}
.app,.workspace{
  min-width:0;
}
.content-frame{
  height:calc(100dvh - 54px)!important;
}
.welcome{
  height:calc(100dvh - 54px)!important;
}
html.embedded-process body{
  overflow:auto!important;
}
html.embedded-process .top,
html.embedded-process .bottom{
  display:none!important;
}
html.embedded-process .wrap{
  padding-top:28px!important;
  padding-bottom:45px!important;
}
html.embedded-process .layout{
  padding-top:18px!important;
}

/* Foto editorial da Missão: configurações de tema não podem ampliar e cortar o rosto. */
html[data-page="missao"] .mission-intro-photo img{
  object-position:center 16%!important;
  transform:none!important;
}

/* Contraste da missão ativa: autoria e título precisam permanecer legíveis no tema claro. */
html[data-page="missao"] .mission-card .author b{
  color:#fffdf4!important;font-size:15px!important;font-weight:850!important;
  text-shadow:0 2px 5px rgba(0,0,0,.58)!important;
}
html[data-page="missao"] .mission-card .author small{
  color:#e9dfc9!important;font-size:10px!important;font-weight:650!important;
  text-shadow:0 1px 4px rgba(0,0,0,.52)!important;
}
html[data-page="missao"] .mission-card .mission-main h2{
  color:#fffdf4!important;font-size:clamp(44px,4vw,56px)!important;line-height:1.06!important;
  font-weight:600!important;text-shadow:0 3px 10px rgba(0,0,0,.58)!important;
}

/* Sistema visual das atividades: verde profundo, ouro vivo e leitura clara. */
html[data-page="missao"] .activity-chat,
html[data-page="missao"] .mission-participants,
html[data-page="missao"] .mission-board{
  background:linear-gradient(145deg,#31492d 0%,#21351f 100%)!important;
  border-color:rgba(243,201,109,.36)!important;
  box-shadow:0 18px 44px rgba(19,39,23,.16)!important;
}
html[data-page="missao"] .activity-chat .eyebrow,
html[data-page="missao"] .mission-participants .eyebrow,
html[data-page="missao"] .mission-board .eyebrow{color:#f3c96d!important;font-weight:900!important;text-shadow:0 1px 4px rgba(0,0,0,.36)!important}
html[data-page="missao"] .activity-chat h2,
html[data-page="missao"] .activity-chat h3,
html[data-page="missao"] .mission-participants h2,
html[data-page="missao"] .mission-board h2{color:#fffdf4!important;text-shadow:0 2px 8px rgba(0,0,0,.4)!important}
html[data-page="missao"] .activity-chat .chat-head p,
html[data-page="missao"] .mission-participants p,
html[data-page="missao"] .mission-board p{color:#e6eadf!important}
html[data-page="missao"] .activity-chat .chat-count,
html[data-page="missao"] .mission-board .board-date{background:#112015!important;border-color:rgba(243,201,109,.48)!important;color:#fff3d3!important}
html[data-page="missao"] .activity-chat .chat-count b,
html[data-page="missao"] .mission-board .board-date{color:#f3c96d!important}
html[data-page="missao"] .activity-chat .chat-message,
html[data-page="missao"] .mission-board .member,
html[data-page="missao"] .mission-board .board-column{background:#142615!important;border-color:rgba(243,201,109,.24)!important}
html[data-page="missao"] .activity-chat .chat-body-top b,
html[data-page="missao"] .mission-board .member-name,
html[data-page="missao"] .mission-board .participant-line b{color:#fffdf4!important}
html[data-page="missao"] .activity-chat .chat-body-top small,
html[data-page="missao"] .activity-chat .chat-actions button,
html[data-page="missao"] .mission-board small{color:#d9e0d4!important}
html[data-page="missao"] .activity-chat .chat-tools button{background:#112015!important;border-color:rgba(243,201,109,.34)!important;color:#f3c96d!important}

html[data-page="missao"] .response-actions{grid-template-columns:repeat(3,minmax(0,1fr))!important}
html[data-page="missao"] .response-actions .btn{min-height:50px!important}
@media(max-width:600px){html[data-page="missao"] .response-actions{grid-template-columns:1fr!important}}

@media (min-width:1500px){
  .sidebar{
    flex-basis:280px!important;
    width:280px!important;
    padding-inline:24px!important;
  }
  .wrap{
    width:min(1780px,100%)!important;
    padding-top:clamp(34px,2.2vw,52px)!important;
  }
  .top-inner{
    width:min(1780px,100%)!important;
  }
  .community{
    grid-template-columns:minmax(0,1fr) minmax(320px,390px)!important;
    justify-content:stretch;
  }
  .community-shell{
    max-width:none!important;
    width:100%!important;
  }
  .media{
    height:clamp(500px,34vw,680px)!important;
  }
  .welcome-inner{
    max-width:1680px!important;
  }
  .welcome h1{
    font-size:clamp(52px,3.6vw,72px)!important;
  }
  .cards{
    gap:18px!important;
  }
  .page{
    max-width:1480px;
  }
}

@media (min-width:1700px){
  .mission-layout,.journey-hero{
    grid-template-columns:minmax(0,1fr) minmax(350px,420px)!important;
  }
  .two{
    grid-template-columns:minmax(0,1fr) minmax(360px,.62fr)!important;
  }
  .three{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
  }
  .four{
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
  }
}

@media (max-width:1180px){
  .wrap{
    padding-inline:clamp(14px,2.8vw,28px)!important;
  }
  .community{
    grid-template-columns:minmax(0,1fr) minmax(260px,300px)!important;
    gap:18px!important;
  }
  .publish-grid{
    grid-template-columns:minmax(0,1fr) minmax(280px,.9fr)!important;
  }
}

@media (max-width:1024px){
  .detach,
  .nav-add{
    display:none!important;
  }
  .app.menu-hidden .toolbar,
  .app.menu-hidden .tab-strip,
  .app.menu-hidden .content-frame,
  .app.menu-hidden .welcome{
    width:100%!important;
  }
}

@media (max-width:980px){
  .two,.journey-hero,.mission-layout{
    grid-template-columns:1fr!important;
  }
  .community{
    grid-template-columns:1fr!important;
  }
  .side{
    position:static!important;
    display:block!important;
  }
  .hero-photo{
    opacity:.38;
  }
  .four{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }
  .publish-box,.community-dialog,.profile-modal{
    width:min(760px,calc(100vw - 28px))!important;
  }
}

@media (max-width:760px){
  html,body{
    min-height:100dvh;
  }
  .app{
    display:block!important;
    height:100dvh!important;
    overflow:hidden;
  }
  .workspace{
    width:100%!important;
    height:100dvh!important;
  }
  .toolbar{
    height:58px!important;
    padding-inline:12px!important;
  }
  .toolbar-title{
    font-size:16px!important;
  }
  .tool-btn{
    padding:9px 10px!important;
  }
  .menu-toggle-handle{
    position:fixed!important;
    left:min(276px,calc(86vw - 16px))!important;
    top:12px!important;
    z-index:80!important;
  }
  .sidebar{
    display:block!important;
    position:fixed!important;
    inset:0 auto 0 0!important;
    width:min(292px,86vw)!important;
    flex-basis:auto!important;
    height:100dvh!important;
    padding:24px 16px!important;
    overflow-y:auto!important;
    border-right:1px solid var(--line)!important;
    box-shadow:26px 0 60px rgba(0,0,0,.38);
    transform:translateX(0);
  }
  .app.menu-hidden .sidebar{
    width:min(292px,86vw)!important;
    padding:24px 16px!important;
    border-right:1px solid var(--line)!important;
    transform:translateX(-105%);
  }
  .app.menu-hidden .sidebar>*{
    opacity:1!important;
    pointer-events:auto!important;
  }
  .logout{
    position:static!important;
    margin-top:24px;
    width:100%;
  }
  .show-menu{
    display:none!important;
  }
  .app.menu-hidden .toolbar{
    padding-left:50px!important;
  }
  .app.menu-hidden .menu-toggle-handle{
    left:0!important;
    top:12px!important;
    opacity:.26!important;
  }
  .app.menu-hidden .menu-toggle-handle:hover,
  .app.menu-hidden .menu-toggle-handle:focus-visible{
    opacity:.82!important;
  }
  .content-frame{
    height:calc(100dvh - 58px)!important;
  }
  .welcome{
    height:calc(100dvh - 58px)!important;
    padding:26px 15px 80px!important;
  }
  .welcome h1{
    font-size:clamp(34px,10vw,44px)!important;
  }
  .hero-actions{
    flex-direction:column;
  }
  .hero-actions .btn{
    width:100%;
  }
  .cards{
    grid-template-columns:1fr!important;
  }
  .top{
    height:auto!important;
    min-height:62px;
  }
  .top-inner{
    padding:10px 14px!important;
    gap:12px!important;
  }
  .logo{
    font-size:clamp(30px,8vw,38px)!important;
  }
  .tag{
    display:none!important;
  }
  .top-actions{
    gap:6px!important;
  }
  .icon{
    width:44px!important;
    height:44px!important;
  }
  .wrap{
    padding:20px 13px 96px!important;
  }
  .page{
    width:100%!important;
    padding-inline:12px!important;
  }
  .brand-side{
    min-height:300px!important;
    padding:24px!important;
  }
  .brand-side h1{
    max-width:76%!important;
  }
  .box,.card{
    padding:20px!important;
  }
  .row,.plan-grid{
    grid-template-columns:1fr!important;
  }
  .three,.four,.badge-grid,.board-columns,.publish-grid,.music-tools,.text-tools{
    grid-template-columns:1fr!important;
  }
  .side{
    display:none!important;
  }
  .section-head,.board-head,.publish-head,.composer-card,.journal-footer{
    align-items:flex-start!important;
    flex-direction:column!important;
  }
  .composer-actions,.hero-actions,.profile-actions,.modal-actions,.publish-actions,.composer-actions-row{
    width:100%;
    flex-direction:column!important;
  }
  .composer-actions button,.hero-actions .btn,.profile-actions button,.modal-actions button,.publish-actions button,.composer-actions-row .btn{
    width:100%!important;
  }
  .media{
    height:auto!important;
    min-height:0!important;
    aspect-ratio:1/1;
    max-height:none!important;
  }
  .media.aspect-portrait{aspect-ratio:4/5}
  .media.aspect-landscape{aspect-ratio:1.91/1}
  .media.aspect-vertical{aspect-ratio:9/16}
  .media-content{
    padding:22px!important;
  }
  .media h2{
    font-size:clamp(22px,7vw,30px)!important;
  }
  .story-box{
    width:calc(100vw - 18px)!important;
    height:min(760px,calc(100dvh - 18px))!important;
    border-radius:16px!important;
  }
  .story-bottom h2{
    font-size:clamp(22px,7vw,29px)!important;
  }
  .story-actions{
    display:grid!important;
    grid-template-columns:1fr 1fr 1fr;
  }
  .story-actions button{
    padding-inline:6px!important;
    font-size:8px!important;
  }
  .publish-modal,.profile-panel,.community-modal,.followers-modal,.modal,.story-viewer{
    padding:9px!important;
  }
  .publish-box,.community-dialog,.profile-modal,.followers-box,.modal-box{
    width:calc(100vw - 18px)!important;
    max-height:calc(100dvh - 18px)!important;
    border-radius:18px!important;
    padding:16px!important;
  }
  .publish-preview{
    min-height:0!important;
  }
  .preview-stage{
    min-height:0!important;
    width:100%!important;
  }
  .preview-stage.aspect-square{aspect-ratio:1/1}
  .preview-stage.aspect-portrait{aspect-ratio:4/5}
  .preview-stage.aspect-landscape{aspect-ratio:1.91/1}
  .preview-stage.aspect-vertical{aspect-ratio:9/16}
  .text-overlay{
    max-width:90%!important;
    font-size:clamp(20px,8vw,38px);
  }
  .bottom{
    left:8px!important;
    right:8px!important;
    bottom:8px!important;
    height:64px!important;
    overflow-x:auto;
    justify-content:flex-start!important;
    gap:4px;
    padding:0 8px;
    scrollbar-width:none;
  }
  .bottom::-webkit-scrollbar{
    display:none;
  }
  .bottom button{
    flex:0 0 62px;
    min-width:62px;
  }
  .alert,.toast{
    left:12px!important;
    right:12px!important;
    bottom:84px!important;
    max-width:none!important;
  }
}

/* Telas editoriais: composição segura em celulares estreitos. */
@media (max-width:600px){
  html[data-page="jornada"] .journey-hero{display:block!important}
  html[data-page="jornada"] .hero-panel{min-height:0!important;overflow:hidden!important;padding:24px!important}
  html[data-page="jornada"] .hero-photo-frame{display:none!important}
  html[data-page="jornada"] .hero-copy{max-width:none!important}
  html[data-page="jornada"] .hero-copy h1{font-size:clamp(31px,9vw,38px)!important;line-height:1.1!important}
  html[data-page="jornada"] .hero-actions{display:grid!important;grid-template-columns:1fr!important}
  html[data-page="jornada"] .hero-actions .btn{width:100%!important}

  html[data-page="comunidade"] .community-profile-header{padding:15px!important}
  html[data-page="comunidade"] .community-brand-photo{height:220px!important;min-height:220px!important;margin:0!important}
  html[data-page="comunidade"] .community-brand-photo img{object-position:center top!important;transform:none!important}

  html[data-page="missao"] .mission-intro-photo{width:100%!important;max-width:340px!important;margin-inline:auto!important}
  html[data-page="missao"] .mission-intro-photo>div{height:300px!important}
  html[data-page="missao"] .mission-intro-photo img{object-position:center 20%!important;transform:none!important}

  html[data-page="ao-vivo"] .live-premium-intro{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:22px!important;padding:24px!important}
  html[data-page="ao-vivo"] .live-premium-intro .title{font-size:clamp(38px,11vw,48px)!important}
  html[data-page="ao-vivo"] .live-hero-photo{width:100%!important;flex:0 0 auto!important;height:240px!important;transform:none!important}
  html[data-page="ao-vivo"] .live-hero-photo img{object-position:center 25%!important;transform:none!important}
  html[data-page="ao-vivo"] .live-admin-create{width:100%!important}
  html[data-page="ao-vivo"] .live-agenda{padding:22px!important}
}

/* iOS amplia a página ao focar controles com texto menor que 16px.
   Os formulários mantêm a escala do app e continuam navegáveis por pinça. */
@media (max-width:700px){
  html[data-page="ao-vivo"] .live-schedule-modal{
    min-height:100dvh!important;height:100dvh!important;align-items:flex-start!important;
    overflow-y:auto!important;overflow-x:hidden!important;padding:12px!important;
    overscroll-behavior:contain;-webkit-overflow-scrolling:touch;
  }
  html[data-page="ao-vivo"] .live-schedule-card{
    width:100%!important;max-height:calc(100dvh - 24px)!important;overflow-y:auto!important;
    overflow-x:hidden!important;padding:22px 16px!important;border-radius:20px!important;
  }
  html[data-page="ao-vivo"] .live-schedule-grid{grid-template-columns:1fr!important;gap:14px!important}
  html[data-page="ao-vivo"] .live-schedule-card input,
  html[data-page="ao-vivo"] .live-schedule-card textarea,
  html[data-page="ao-vivo"] .live-schedule-card select,
  html[data-page="ao-vivo"] .live-schedule-card button{font-size:16px!important}
  html[data-page="ao-vivo"] .live-schedule-card textarea{min-height:120px!important;resize:vertical}
}

@media (max-width:420px){
  .wrap{
    padding-inline:10px!important;
  }
  .title{
    font-size:clamp(27px,8.4vw,33px)!important;
  }
  .card,.post,.composer-card,.mission-card,.hero-panel,.publish-box,.community-dialog,.profile-modal,.followers-box{
    border-radius:16px!important;
  }
  .head{
    padding-inline:10px!important;
  }
  .avatar{
    width:36px!important;
    height:36px!important;
  }
  .action-row{
    gap:4px!important;
    padding-inline:9px!important;
  }
  .action{
    width:32px!important;
    height:32px!important;
  }
  .music-bar{
    margin-inline:9px!important;
    flex-wrap:wrap;
  }
  .profile-stats,.stats,.stat-strip{
    gap:6px!important;
  }
}

@media (orientation:landscape) and (max-height:520px){
  .top{
    position:relative!important;
  }
  .bottom{
    display:none!important;
  }
  .wrap{
    padding-bottom:30px!important;
  }
  .story-box{
    height:calc(100dvh - 16px)!important;
    width:min(420px,calc(100vw - 16px))!important;
  }
}

@media (min-width:1800px){
  body{
    font-size:17px;
  }
  .card{
    padding:clamp(21px,1.25vw,30px)!important;
  }
}

.app.has-tabs .content-frame,
.app.has-tabs .welcome{
  height:calc(100dvh - 96px)!important;
}
.app.menu-hidden .tab-strip{
  width:calc(100vw - var(--open-sidebar-width))!important;
  max-width:100%!important;
}
.sidebar .nav{
  gap:7px!important;
}
.sidebar .nav button{
  min-height:44px!important;
  gap:14px!important;
  padding:13px 10px 13px 14px!important;
  font-size:14.5px!important;
  font-weight:520!important;
  letter-spacing:.01em!important;
}
.sidebar .navicon{
  width:22px!important;
  font-size:18px!important;
  line-height:1!important;
}
.sidebar .nav-add{
  width:27px!important;
  height:27px!important;
  font-size:19px!important;
}
.sidebar .logout{
  min-height:38px!important;
  font-size:10.5px!important;
}

@media (max-width:760px){
  .app.has-tabs .content-frame,
  .app.has-tabs .welcome{
    height:calc(100dvh - 100px)!important;
  }
  .app.menu-hidden .tab-strip{
    width:100%!important;
  }
}

/* Feed da comunidade: posts sempre inteiros, sem corte lateral em celular/tablet/desktop. */
html.embedded-process,
html.embedded-process body{
  max-width:100%!important;
  overflow-x:hidden!important;
}
.community,
.community section,
.post,
.media,
.media-content,
.caption,
.comments{
  min-width:0!important;
  max-width:100%!important;
}
.community{
  width:100%!important;
}
.post{
  width:100%!important;
  overflow:hidden!important;
}
.media{
  width:100%!important;
}
.media-content{
  width:calc(100% - clamp(28px,7vw,72px))!important;
  max-width:680px!important;
  justify-self:center!important;
  margin:auto!important;
  padding:0!important;
  overflow-wrap:anywhere!important;
  word-break:normal!important;
  white-space:normal!important;
}
.media h2,
.media p{
  display:block!important;
  max-width:100%!important;
  overflow-wrap:anywhere!important;
  word-break:normal!important;
  white-space:normal!important;
}
.media h2{
  font-size:clamp(25px,4.2vw,34px)!important;
  line-height:1.08!important;
}
.media p{
  width:100%!important;
  max-width:520px!important;
  margin-inline:auto!important;
  line-height:1.48!important;
}
.media.uploaded,
.media.uploaded.aspect-square,
.media.uploaded.aspect-portrait,
.media.uploaded.aspect-landscape,
.media.uploaded.aspect-vertical,
.media.uploaded.aspect-custom,
.media.uploaded.aspect-original{
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
}
.media.uploaded img,
.media.uploaded video{
  width:100%!important;
  height:100%!important;
  max-height:none!important;
  object-fit:contain!important;
  object-position:center center!important;
  background:#060b05!important;
}
.media.uploaded.aspect-original,
.media.uploaded.aspect-custom,
.preview-stage.aspect-original,
.preview-stage.aspect-custom{
  aspect-ratio:var(--media-ratio,4/5)!important;
}

.publish-size-panel{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px;
  margin-top:8px;
  padding:9px;
  border:1px solid rgba(240,202,117,.2);
  border-radius:12px;
  background:rgba(10,16,8,.24);
}
.publish-size-panel[hidden]{
  display:none!important;
}
.publish-size-detected{
  grid-column:1/-1;
  color:#b9c4ad;
  font-size:9px;
  line-height:1.3;
}
.publish-size-detected strong{
  color:var(--gold2,#f0ca75);
  font-weight:850;
}
.publish-size-panel label{
  display:grid!important;
  gap:5px;
  margin:0!important;
  color:#d9d4c6;
  font-size:8.5px!important;
  letter-spacing:1px;
  text-transform:uppercase;
}
.publish-size-panel input{
  min-height:36px!important;
  padding:7px 9px!important;
  text-align:center;
}

/* Editor de postagem: tela unica no desktop, sem rolagem interna aparente. */
@media (min-width:981px){
  .publish-modal{
    padding:clamp(10px,1.4vw,20px)!important;
  }
  .publish-box{
    width:min(1320px,calc(100vw - 32px))!important;
    max-height:calc(100dvh - 24px)!important;
    overflow:hidden!important;
    display:flex!important;
    flex-direction:column!important;
    padding:18px 20px 16px!important;
  }
  .publish-head{
    align-items:center!important;
    flex:0 0 auto!important;
  }
  .publish-head h3{
    margin-bottom:3px!important;
    font-size:clamp(24px,2vw,30px)!important;
  }
  .publish-head p{
    max-width:850px!important;
  }
  .publish-close{
    flex:0 0 auto!important;
  }
  .publish-grid{
    flex:1 1 auto!important;
    min-height:0!important;
    display:grid!important;
    grid-template-columns:minmax(0,1.1fr) minmax(320px,.74fr)!important;
    gap:16px!important;
    margin-top:12px!important;
    align-items:stretch!important;
  }
  .publish-grid > div:first-child{
    min-width:0!important;
    min-height:0!important;
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:9px 11px!important;
    align-content:start!important;
  }
  .publish-grid > div:first-child > .publish-field,
  .publish-grid > div:first-child > .music-preview-btn,
  .publish-grid > div:first-child > .music-note,
  .publish-grid > div:first-child > .publish-error{
    margin-top:0!important;
  }
  .publish-grid > div:first-child > .text-tools,
  .publish-grid > div:first-child > .music-tools,
  .publish-grid > div:first-child > .publish-error{
    grid-column:1/-1!important;
  }
  .publish-grid > div:first-child > .music-preview-btn{
    grid-column:1/2!important;
    justify-self:start!important;
    align-self:center!important;
    min-height:38px!important;
    margin-top:0!important;
  }
  .publish-grid > div:first-child > .music-note{
    grid-column:2/3!important;
    align-self:center!important;
    margin-top:0!important;
  }
  .publish-field label{
    margin-bottom:5px!important;
    font-size:9px!important;
  }
  .publish-field input,
  .publish-field select,
  .publish-field textarea{
    min-height:40px!important;
    border-radius:11px!important;
    padding:9px 11px!important;
  }
  .publish-field textarea{
    min-height:74px!important;
    max-height:88px!important;
    resize:none!important;
  }
  .publish-aspect-hint{
    margin-top:5px!important;
    font-size:8.5px!important;
    line-height:1.35!important;
  }
  .text-manager{
    margin-top:8px!important;
  }
  .text-manager button,
  .overlay-list button{
    min-height:32px!important;
    padding:7px 10px!important;
  }
  .overlay-list{
    margin-top:7px!important;
  }
  .text-tools{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:9px 10px!important;
    margin-top:0!important;
  }
  .text-tools input[type=color]{
    height:40px!important;
  }
  .text-size-row,
  .shadow-opacity-row{
    min-height:40px!important;
    margin-top:0!important;
  }
  .music-tools{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:10px!important;
    margin-top:0!important;
  }
  .publish-preview{
    min-width:0!important;
    min-height:0!important;
    height:100%!important;
    align-self:stretch!important;
    padding:12px!important;
  }
  .publish-preview .preview-stage{
    min-height:0!important;
    max-height:100%!important;
  }
  .preview-stage.aspect-square,
  .preview-stage.aspect-portrait,
  .preview-stage.aspect-landscape,
  .preview-stage.aspect-vertical,
  .preview-stage.aspect-custom,
  .preview-stage.aspect-original{
    height:100%!important;
    max-height:100%!important;
  }
  .publish-actions{
    flex:0 0 auto!important;
    margin-top:12px!important;
    padding-top:10px!important;
    border-top:1px solid rgba(169,194,149,.18)!important;
  }
  .publish-actions button{
    min-width:150px!important;
  }
}

@media (min-width:681px) and (max-width:980px){
  .publish-box{
    width:calc(100vw - 24px)!important;
  }
  .publish-grid{
    grid-template-columns:minmax(0,1fr) minmax(280px,.82fr)!important;
    gap:12px!important;
  }
  .publish-field textarea{
    min-height:86px!important;
  }
  .text-tools{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }
}

@media (min-width:981px) and (max-height:740px){
  .publish-box{
    padding:14px 18px 12px!important;
  }
  .publish-head h3{
    font-size:24px!important;
  }
  .publish-head p{
    font-size:10px!important;
  }
  .publish-grid{
    gap:12px!important;
    margin-top:8px!important;
  }
  .publish-grid > div:first-child{
    gap:7px 9px!important;
  }
  .publish-field label{
    margin-bottom:4px!important;
    font-size:8.5px!important;
  }
  .publish-field input,
  .publish-field select,
  .publish-field textarea{
    min-height:36px!important;
    padding:7px 10px!important;
  }
  .publish-field textarea{
    min-height:58px!important;
    max-height:58px!important;
  }
  .publish-aspect-hint{
    margin-top:4px!important;
    font-size:8px!important;
  }
  .publish-size-panel{
    gap:6px!important;
    margin-top:5px!important;
    padding:7px!important;
  }
  .publish-size-detected{
    font-size:8px!important;
  }
  .publish-size-panel input{
    min-height:30px!important;
    padding:5px 7px!important;
  }
  .text-manager{
    gap:7px!important;
    margin-top:6px!important;
  }
  .text-manager button,
  .overlay-list button{
    min-height:28px!important;
    padding:6px 9px!important;
  }
  .overlay-list{
    margin-top:6px!important;
  }
  .text-tools{
    gap:7px 9px!important;
  }
  .text-tools input[type=color],
  .text-size-row,
  .shadow-opacity-row{
    height:36px!important;
    min-height:36px!important;
  }
  .music-tools{
    gap:9px!important;
  }
  .music-preview-btn{
    min-height:34px!important;
    padding:7px 11px!important;
  }
  .music-note{
    font-size:8px!important;
    line-height:1.28!important;
  }
  .publish-actions{
    margin-top:8px!important;
    padding-top:8px!important;
  }
  .publish-actions button{
    padding:9px 14px!important;
  }
}

@media (max-width:980px){
  .community{
    grid-template-columns:1fr!important;
  }
  .community .side{
    display:none!important;
  }
}

@media (max-width:760px){
  .wrap{
    width:100%!important;
    max-width:100%!important;
    overflow-x:hidden!important;
  }
  .post{
    border-radius:18px!important;
  }
  .post .head{
    align-items:center!important;
    gap:10px!important;
    padding:12px!important;
  }
  .post .who{
    min-width:0!important;
  }
  .post .who b,
  .post .who small{
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
  }
  .media:not(.uploaded){
    height:auto!important;
    min-height:0!important;
    aspect-ratio:4/5!important;
  }
  .media-content{
    width:calc(100% - 32px)!important;
    padding:0!important;
  }
  .media h2{
    font-size:clamp(25px,8vw,34px)!important;
  }
  .media p{
    font-size:12px!important;
  }
  .action-row{
    flex-wrap:nowrap!important;
    overflow-x:auto!important;
    scrollbar-width:none!important;
  }
  .action-row::-webkit-scrollbar{
    display:none!important;
  }
  .caption,
  .comments,
  .likes{
    padding-inline:12px!important;
    max-width:100%!important;
    overflow-wrap:anywhere!important;
    word-break:normal!important;
    white-space:normal!important;
  }
}

@media (max-width:420px){
  .media-content{
    padding:20px 14px!important;
  }
  .media h2{
    font-size:clamp(23px,8.4vw,31px)!important;
  }
}
