/* View page - BEM methodology with design from references/notice-sub.html */

/* Box sizing for the view */
.sbr2-view *, 
.sbr2-view *::before, 
.sbr2-view *::after { 
  box-sizing: border-box; 
}

/* Main container */
.sbr2-view {
  padding: 0 15px;
  margin: 0 auto;
  max-width: 1700px;
}

/* Top section */
.sbr2-view__top {
  padding: 60px 0 25px;
  border-bottom: 1px solid #222;
}

.sbr2-view__title {
  font-size: 35px;
  color: #111;
  font-weight: 500;
  margin: 0 0 45px 0;
  line-height: 1.4;
}

.sbr2-view__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.sbr2-view__meta-left {
  display: flex;
  align-items: center;
  gap: 15px;
  color: #333;
}

.sbr2-view__date {
  font-size: 17px;
  color: #333;
}

.sbr2-view__author {
  padding-top: 2px;
}

.sbr2-view__separator {
  font-size: 35px;
  color: #DADADA;
  font-weight: 300;
}

.sbr2-view__views {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 17px;
  margin: 0;
  color: #333;
}

.sbr2-view__views-icon {
  display: block;
  width: 20px;
  height: 20px;
  background: url(../img/view-ico.png) no-repeat center/contain;
}

.sbr2-view__meta-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sbr2-view__action {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 50px;
  height: 50px;
  border: 1px solid #e4e4e4;
  border-radius: 5px;
  text-decoration: none;
  transition: all 0.3s ease;
}

.sbr2-view__action:hover {
  background: #f8f9fa;
  border-color: #066AAF;
}

.sbr2-view__action img {
  display: block;
  width: 25px;
  height: 25px;
  object-fit: contain;
}

/* Content section */
.sbr2-view__content {
  padding: 70px 0 100px;
  padding-bottom: 20px;
}

.sbr2-view__thumbnail {
  margin-bottom: 50px;
}

.sbr2-view__thumbnail-img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 700px;
  object-fit: contain;
}

.sbr2-view__text {
  display: block;
  padding: 50px 0;
  font-size: 19px;
  color: #111;
  line-height: 1.6;
  margin-bottom: 50px;
}

.sbr2-view__text p {
  font-size: 19px;
  color: #111;
  line-height: 1.6;
  margin: 0 0 1.5em 0;
}

.sbr2-view__text p:last-child {
  margin-bottom: 0;
}

/* Attachments section */
.sbr2-view__attachments {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 35px;
  color: #DADADA;
  border: 1px solid #DADADA;
  padding: 26px 35px;
  font-weight: 300;
  list-style: none;
  margin: 0;
}

.sbr2-view__attachments-label {
  font-size: 16px;
  font-weight: 600;
  color: #111;
}

.sbr2-view__attachments-separator {
  font-size: 35px;
  color: #DADADA;
  font-weight: 300;
}

.sbr2-view__attachments-item {
  display: flex !important;
  align-items: center;
  gap: 15px;
}

.sbr2-view__attachments-link {
  font-size: 20px;
  color: #111;
  text-decoration: none;
  transition: color 0.3s ease;
}

.sbr2-view__attachments-link:hover {
  color: #066AAF;
  text-decoration: underline;
}

.sbr2-view__attachments-icon {
  display: block;
  width: 19px;
  height: 19px;
  background: url(../img/download.png) no-repeat center/contain;
  cursor: pointer;
}

.sbr2-view__note {
  padding: 20px;
  background: #f8f9fa;
  color: #666;
  border-radius: 5px;
  margin: 20px 0;
}

/* Navigation section */
.sbr2-view__nav {
  border-top: 1px solid #111;
  border-bottom: 1px solid #111;
  margin-bottom: 80px;
}

.sbr2-view__nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sbr2-view__nav-item {
  padding: 40px 50px;
}

.sbr2-view__nav-item--prev {
  border-bottom: 1px solid #E8E8E8;
}

.sbr2-view__nav-link,
.sbr2-view__nav-disabled {
  display: flex;
  align-items: center;
  gap: 40px;
  text-decoration: none;
  color: inherit;
}

.sbr2-view__nav-label {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sbr2-view__nav-label p {
  font-size: 18px;
  color: #111;
  font-weight: 500;
  margin: 0;
}

.sbr2-view__nav-item--next .sbr2-view__nav-label p {
  color: #066AAF;
}

.sbr2-view__nav-icon {
  display: block;
  width: 16px;
  height: 16px;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
}

.sbr2-view__nav-icon--prev {
  background-image: url(../img/up.png);
}

.sbr2-view__nav-icon--next {
  background-image: url(../img/up-blue.png);
  transform: rotate(180deg);
}

.sbr2-view__nav-title {
  font-size: 18px;
  color: #222;
  line-height: 1.5;
  margin: 0;
  flex: 1;
}

.sbr2-view__nav-disabled {
  opacity: 0.5;
  cursor: default;
}

.sbr2-view__nav-disabled .sbr2-view__nav-title {
  color: #999;
}

/* Action buttons */
.sbr2-view__actions {
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 40px 0;
}

.sbr2-view__button {
  display: inline-block;
  padding: 15px 40px;
  font-size: 18px;
  font-weight: 500;
  text-decoration: none;
  border-radius: 5px;
  transition: all 0.3s ease;
  cursor: pointer;
  border: 1px solid transparent;
}

.sbr2-view__button--list {
  background: #066AAF;
  color: #fff;
  border-color: #066AAF;
}

.sbr2-view__button--list:hover {
  background: #055890;
  border-color: #055890;
  color: white;
}

.sbr2-view__button--edit {
  background: #fff;
  color: #066AAF;
  border-color: #066AAF;
}

.sbr2-view__button--edit:hover {
  background: #f0f8ff;
}

/* Comments section */
.sbr2-view__comments {
  margin: 40px 0;
}

/* Responsive styles */
@media all and (max-width: 768px) {
  .sbr2-view__title {
    font-size: 28px;
    margin-bottom: 30px;
  }
  
  .sbr2-view__meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
  
  .sbr2-view__meta-left {
    font-size: 15px;
  }
  
  .sbr2-view__date,
  .sbr2-view__views {
    font-size: 15px;
  }
  
  .sbr2-view__separator {
    font-size: 25px;
  }
  
  .sbr2-view__action {
    width: 45px;
    height: 45px;
  }
  
  .sbr2-view__action img {
    width: 22px;
    height: 22px;
  }
  
  .sbr2-view__content {
    padding: 50px 0 70px;
    padding-bottom: 20px;
  }
  
  .sbr2-view__text {
    font-size: 17px;
    padding: 30px 0;
  }
  
  .sbr2-view__text p {
    font-size: 17px;
  }
  
  .sbr2-view__attachments {
    flex-wrap: wrap;
    padding: 20px;
    gap: 15px;
  }
  
  .sbr2-view__attachments-label,
  .sbr2-view__attachments-link {
    font-size: 16px;
  }
  
  .sbr2-view__nav-item {
    padding: 30px 20px;
  }
  
  .sbr2-view__nav-link,
  .sbr2-view__nav-disabled {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
  
  .sbr2-view__nav-label p {
    font-size: 16px;
  }
  
  .sbr2-view__nav-title {
    font-size: 16px;
  }
  
  .sbr2-view__actions {
    flex-direction: column;
    align-items: stretch;
    padding: 30px 0;
  }
  
  .sbr2-view__button {
    text-align: center;
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
  }
}

/* Print styles: show only top + content */
@media print {
  /* Page and color behavior */
  @page { margin: 16mm; }
  body { -webkit-print-color-adjust: exact; print-color-adjust: exact; }

  /* Hide everything by default, then reveal the board view */
  body * { visibility: hidden !important; }
  .sbr2-view, .sbr2-view * { visibility: visible !important; }

  /* Position the printable area at the top-left and use full width */
  .sbr2-view {
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
  }

  /* Hide sections not wanted in print */
  .sbr2-view__meta-right,
  .sbr2-view__nav,
  .sbr2-view__actions,
  .sbr2-view__comments { display: none !important; }

  /* Make links readable in print */
  a { color: #000 !important; text-decoration: underline !important; }
  .sbr2-view__attachments-link { color: #000 !important; }
}

@media all and (max-width: 480px) {
  .sbr2-view__title {
    font-size: 24px;
  }
  
  .sbr2-view__thumbnail-img {
    max-height: 400px;
  }
  
  .sbr2-view__text {
    font-size: 16px;
  }
  
  .sbr2-view__text p {
    font-size: 16px;
  }
  
  .sbr2-view__attachments {
    font-size: 14px;
  }
  
  .sbr2-view__attachments-label,
  .sbr2-view__attachments-link {
    font-size: 14px;
  }
}
