/* Public Pages Shared Styles */
.public-container {
  position: relative;
  min-height: 100vh;
  width: 100%;
  padding: 2rem;
  box-sizing: border-box;
}

.public-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background: linear-gradient(135deg, #1a1a4e 0%, #2d1b69 50%, #1a1a4e 100%);
}

.public-content {
  max-width: 900px;
  margin: 0 auto;
}

/* Glass Card for Public Pages */
.public-glass-card {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 2rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  margin-bottom: 1.5rem;
}

/* Page Header */
.public-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.public-header h1 {
  color: #fff;
  font-size: 2rem;
  margin: 0;
}

.public-header .back-link {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s;
}

.public-header .back-link:hover {
  color: #fff;
}

/* Announcement List Styles */
.announcement-list-public {
  list-style: none;
  padding: 0;
  margin: 0;
}

.announcement-list-item {
  padding: 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.announcement-list-item:last-child {
  border-bottom: none;
}

.announcement-list-item a {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  display: block;
  transition: color 0.2s;
}

.announcement-list-item a:hover {
  color: #fff;
}

.announcement-list-item .title {
  font-size: 1.1rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.announcement-list-item .pinned-badge {
  display: inline-block;
  background: rgba(255, 193, 7, 0.3);
  color: #ffc107;
  font-size: 0.7rem;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  margin-right: 0.5rem;
  font-weight: 600;
}

.announcement-list-item .meta {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}

/* Announcement Detail */
.announcement-detail {
  color: rgba(255, 255, 255, 0.9);
}

.announcement-detail .title {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: #fff;
}

.announcement-detail .meta {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.announcement-detail .content {
  line-height: 1.8;
}

.announcement-detail .content a {
  color: #7dd3fc;
}

.announcement-detail .attachments {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.announcement-detail .attachments h4 {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
  margin-bottom: 0.75rem;
}

.announcement-detail .attachments a {
  color: #7dd3fc;
  text-decoration: none;
}

.announcement-detail .attachments a:hover {
  text-decoration: underline;
}

/* Gallery Grid Styles */
.gallery-grid-public {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.gallery-grid-item {
  aspect-ratio: 1;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  background: rgba(255, 255, 255, 0.05);
}

.gallery-grid-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.3s;
}

.gallery-grid-item:hover img {
  transform: scale(1.05);
}

.gallery-grid-item .overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
  padding: 1rem;
  color: #fff;
}

.gallery-grid-item .overlay .title {
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gallery-grid-item .overlay .date {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.6);
}

/* Gallery Detail */
.gallery-detail {
  color: rgba(255, 255, 255, 0.9);
}

.gallery-detail .title {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: #fff;
}

.gallery-detail .meta {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 1.5rem;
}

.gallery-detail .description {
  line-height: 1.8;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.gallery-detail .images {
  display: grid;
  gap: 1rem;
}

.gallery-detail .images img {
  width: 100%;
  border-radius: 8px;
}

/* Quill Editor Content Styles */
.announcement-detail .content .ql-align-center,
.gallery-detail .description .ql-align-center {
  text-align: center;
}

.announcement-detail .content .ql-align-right,
.gallery-detail .description .ql-align-right {
  text-align: right;
}

.announcement-detail .content .ql-align-justify,
.gallery-detail .description .ql-align-justify {
  text-align: justify;
}

/* Quill indent classes */
.announcement-detail .content .ql-indent-1,
.gallery-detail .description .ql-indent-1 { padding-left: 3em; }

.announcement-detail .content .ql-indent-2,
.gallery-detail .description .ql-indent-2 { padding-left: 6em; }

.announcement-detail .content .ql-indent-3,
.gallery-detail .description .ql-indent-3 { padding-left: 9em; }

/* Basic content styles */
.announcement-detail .content p,
.gallery-detail .description p {
  margin: 0 0 1em 0;
}

.announcement-detail .content h1,
.announcement-detail .content h2,
.announcement-detail .content h3,
.gallery-detail .description h1,
.gallery-detail .description h2,
.gallery-detail .description h3 {
  margin: 1.5em 0 0.5em 0;
  color: #fff;
}

.announcement-detail .content h1,
.gallery-detail .description h1 { font-size: 2em; }

.announcement-detail .content h2,
.gallery-detail .description h2 { font-size: 1.5em; }

.announcement-detail .content h3,
.gallery-detail .description h3 { font-size: 1.17em; }

.announcement-detail .content ul,
.announcement-detail .content ol,
.gallery-detail .description ul,
.gallery-detail .description ol {
  margin: 0 0 1em 0;
  padding-left: 1.5em;
}

.announcement-detail .content li,
.gallery-detail .description li {
  margin-bottom: 0.5em;
}

.announcement-detail .content blockquote,
.gallery-detail .description blockquote {
  border-left: 4px solid rgba(255, 255, 255, 0.3);
  padding-left: 1em;
  margin: 1em 0;
  color: rgba(255, 255, 255, 0.7);
}

.announcement-detail .content pre,
.gallery-detail .description pre {
  background: rgba(0, 0, 0, 0.3);
  padding: 1em;
  border-radius: 4px;
  overflow-x: auto;
}

.announcement-detail .content img,
.gallery-detail .description img {
  max-width: 100%;
  height: auto;
}

/* Empty State */
.public-empty-state {
  color: rgba(255, 255, 255, 0.5);
  text-align: center;
  padding: 3rem;
  font-size: 1rem;
}

/* Responsive */
@media (max-width: 768px) {
  .public-container {
    padding: 1rem;
  }

  .public-glass-card {
    padding: 1.25rem;
  }

  .public-header h1 {
    font-size: 1.5rem;
  }

  .gallery-grid-public {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .gallery-grid-public {
    grid-template-columns: 1fr;
  }
}
