
/* RUYA BULLETIN MODAL V1
   Data-safe: only bulletin upload/preview UI
*/

.ruyaBulletinModal{
  width:min(920px,calc(100vw - 24px)) !important;
  max-width:920px !important;
  height:min(92dvh,900px) !important;
  max-height:92dvh !important;

  display:flex !important;
  flex-direction:column !important;

  overflow:hidden !important;
  padding-bottom:0 !important;
}

/* Üst başlık sabit */
.ruyaBulletinModal .uploadModalHeader{
  flex:0 0 auto;
  position:relative;
  z-index:30;
  background:#fff;
}

/* Sadece orta alan scroll */
.ruyaBulletinModal .uploadModalBody{
  flex:1 1 auto !important;
  min-height:0 !important;

  overflow-y:auto !important;
  overflow-x:hidden !important;
  overscroll-behavior:contain;

  padding-bottom:0 !important;
  scrollbar-gutter:stable;
}

/* Önizleme tam genişlik */
.ruyaBulletinModal .ruyaProgramPreview,
.ruyaBulletinModal .ruyaProgramDayEditor{
  width:100% !important;
  max-width:none !important;
  box-sizing:border-box;
}

/* Bülten satırı:
   sıra | içerik | yukarı | aşağı | sil
*/
.ruyaBulletinModal .ruyaProgramEditRow{
  display:grid !important;
  grid-template-columns:
    28px
    minmax(0,1fr)
    34px
    34px
    34px !important;

  align-items:center !important;
  gap:7px !important;
  width:100% !important;
}

/* İçerik alanı artık sıkışmayacak */
.ruyaBulletinModal .ruyaProgramEditRow input:not(.ruyaProgramTime){
  width:100% !important;
  min-width:0 !important;
  max-width:none !important;
  box-sizing:border-box !important;
}

/* Sağdaki kontrol butonları */
.ruyaBulletinModal .ruyaProgramEditRow button{
  width:34px !important;
  min-width:34px !important;
  height:38px !important;
  padding:0 !important;
}

/* ALT BUTONLAR DAİMA GÖRÜNÜR */
.ruyaBulletinModal .uploadModalFooter{
  position:sticky !important;
  bottom:0 !important;
  z-index:50 !important;

  flex:0 0 auto !important;

  background:#fff !important;
  border-top:1px solid #e2e8f0 !important;

  margin-top:18px !important;
  padding:
    12px
    0
    max(12px,env(safe-area-inset-bottom))
    0 !important;

  box-shadow:0 -10px 24px rgba(15,23,42,.07);
}

/* Mobil */
@media (max-width:700px){
  .ruyaBulletinModal{
    width:calc(100vw - 12px) !important;
    max-width:none !important;
    height:94dvh !important;
    max-height:94dvh !important;
  }

  .ruyaBulletinModal .uploadModalBody{
    padding-left:12px !important;
    padding-right:12px !important;
  }

  .ruyaBulletinModal .ruyaProgramEditRow{
    grid-template-columns:
      22px
      minmax(0,1fr)
      32px
      32px
      32px !important;

    gap:5px !important;
  }

  .ruyaBulletinModal .ruyaProgramEditRow button{
    width:32px !important;
    min-width:32px !important;
    height:36px !important;
  }

  .ruyaBulletinModal .ruyaProgramDayTabs{
    overflow-x:auto !important;
    flex-wrap:nowrap !important;
    scrollbar-width:none;
  }

  .ruyaBulletinModal .ruyaProgramDayTabs::-webkit-scrollbar{
    display:none;
  }
}


/* RUYA BULLETIN FOOTER FIX V2
   Alt aksiyonlar her zaman görünür.
   Data-safe: yalnızca görünüm düzeni.
*/

.ruyaBulletinModal{
  position:relative !important;
}

/* İçerik footer'ın arkasında kalmasın */
.ruyaBulletinModal .uploadModalBody{
  padding-bottom:86px !important;
}

/* Footer artık scroll akışının parçası değil */
.ruyaBulletinModal .uploadModalFooter{
  position:absolute !important;
  left:0 !important;
  right:0 !important;
  bottom:0 !important;
  z-index:100 !important;

  margin:0 !important;
  padding:
    12px
    18px
    max(12px,env(safe-area-inset-bottom))
    18px !important;

  background:#fff !important;
  border-top:1px solid #e2e8f0 !important;
  box-shadow:0 -10px 24px rgba(15,23,42,.08) !important;
  box-sizing:border-box !important;
}

@media (max-width:700px){
  .ruyaBulletinModal .uploadModalBody{
    padding-bottom:82px !important;
  }

  .ruyaBulletinModal .uploadModalFooter{
    padding-left:12px !important;
    padding-right:12px !important;
  }
}


/* RUYA BULLETIN MODAL STRUCTURE V3
   Body = flex container
   Scroll yalnız uploadModalScroll
   Footer daima modal altında görünür
*/

.ruyaBulletinModal .uploadModalBody{
  display:flex !important;
  flex-direction:column !important;
  flex:1 1 auto !important;
  min-height:0 !important;
  overflow:hidden !important;
  padding-bottom:0 !important;
}

.ruyaBulletinModal .uploadModalScroll{
  flex:1 1 auto !important;
  min-height:0 !important;
  overflow-y:auto !important;
  overflow-x:hidden !important;
  overscroll-behavior:contain;
  scrollbar-gutter:stable;
  padding-bottom:18px !important;
}

.ruyaBulletinModal .uploadModalFooter{
  position:relative !important;
  left:auto !important;
  right:auto !important;
  bottom:auto !important;
  transform:none !important;

  flex:0 0 auto !important;

  margin:0 !important;
  padding:
    12px
    18px
    max(12px,env(safe-area-inset-bottom))
    18px !important;

  background:#fff !important;
  border-top:1px solid #e2e8f0 !important;
  box-shadow:0 -10px 24px rgba(15,23,42,.08) !important;
  z-index:100 !important;
}

@media (max-width:700px){
  .ruyaBulletinModal .uploadModalFooter{
    padding-left:12px !important;
    padding-right:12px !important;
  }
}
