
body {
  background: #f5f7fa;
  font-family: system-ui, Segoe UI, Arial, sans-serif;
  margin: 0;
  padding: 0;
}
.container {
  max-width: 700px;
  margin: 3rem auto 2rem auto;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 4px 32px rgba(60,80,120,0.08);
  padding: 2rem 2rem 2.5rem 2rem;
}
h1 {
  font-size: 2.3rem;
  margin: 0 0 1rem 0;
  color: #274472;
  letter-spacing: -1px;
}
.header-img {
  display: block;
  width: 100%;
  border-radius: 10px;
  margin-bottom: 1.5rem;
  box-shadow: 0 1px 4px #e0e7ef;
}
p {
  color: #222e38;
  font-size: 1.07em;
  line-height: 1.65;
  margin-top: 0.7em;
}
.section-title {
  font-size: 1.22rem;
  color: #4a6fa5;
  margin-top: 2.2rem;
  margin-bottom: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2.2rem;
  margin-bottom: 0.7rem;
}

.section-header .section-title {
  margin: 0;
}

.rss-subscribe-btn {
  color: #3477e3;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 6px;
  background: #e9f1ff;
  transition: background 0.2s ease;
  white-space: nowrap;
}

.rss-subscribe-btn:hover {
  background: #d6eaff;
  text-decoration: none;
}

/* 
  .posts-scrollbox

  Styles a scrollable container for posts with the following features:
  - Limits the maximum height to 280px and enables vertical scrolling for overflow content.
  - Adds spacing below the container with a 2rem margin.
  - Applies rounded corners with an 8px border-radius.
  - Sets a light background color (#f7f8fa) for visual separation.
  - Adds a subtle box-shadow for depth.
  - Provides internal padding for content spacing.
  - Outlines the container with a 1px solid border in a soft blue shade (#e3e9f5).
*/
.posts-scrollbox {
  max-height: 280px;
  overflow-y: auto;
  margin-bottom: 2rem;
  border-radius: 8px;
  background: #f7f8fa;
  box-shadow: 0 0.5px 3px #e0e7ef;
  /** This means: top=1rem, right=1.2rem, bottom=1rem, left=1.2rem */
  padding: 0rem 1rem 1rem 0.2rem;
  border: 1px solid #e3e9f5;
}
ul {
  padding-left: 0;
  margin-bottom: 0;
}
ul li {
  margin-bottom: 1em;
  font-size: 1.07em;
  line-height: 1.5;
  display: block;
}

.post-header {
  display: flex;
  align-items: center;
  margin-bottom: 0.3em;
}

.post-teaser {
  color: #6a7c93;
  font-size: 0.9em;
  line-height: 1.0;
  margin-left: 0;
  font-style: italic;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.post-link {
  text-decoration: none;
  color: #3477e3;
  font-weight: 500;
  transition: color 0.18s;
}
.post-link:hover {
  color: #17408b;
  text-decoration: underline;
}
.post-date {
  color: #6a7c93;
  font-size: 0.98em;
  margin-left: 0.5em;
  font-style: italic;
  white-space: nowrap;
  flex-shrink: 0;
}
.contribute {
  border-left: 4px solid #44c4a1;
  background: #f2fcf8;
  padding: 1.1rem 1.3rem;
  border-radius: 8px;
  margin-top: 1.8rem;
  font-size: 0.8em;
}
/* Custom Scrollbar */
.posts-scrollbox::-webkit-scrollbar {
  width: 8px;
  background: #fff;        /* White scrollbar track */
  border-radius: 2px;
}
.posts-scrollbox::-webkit-scrollbar-thumb {
  background: #e9eef6;     /* Light gray thumb */
  border-radius: 8px;
}
/* Blog post card sections */
h2, h3 {
  color: #4a6fa5;
  margin-top: 2rem;
  margin-bottom: 0.6rem;
  font-size: 1.2rem;
}
.protip, ul, ol {
  margin-bottom: 1.3em;
}
.protip {
  border-left: 4px solid #44c4a1;
  background: #f2fcf8;
  padding: 1rem 1.25rem;
  border-radius: 7px;
}
code, pre {
  background: #f7f8fa;
  color: #293247;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 1em;
  font-family: "Fira Mono", Consolas, "Courier New", monospace;
}
ul, ol {
  margin-left: 1.4em;
}
em {
  color: #888;
  font-size: 0.95em;
}
@media (max-width: 700px) {
  .container { padding: 1rem 0.5rem; }
  .header-img { margin-bottom: 1rem; }
  .posts-scrollbox { max-height: 200px; }
  
  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
}
@media (max-width: 640px) {
  .container { padding: 1rem 0.5rem; }
  
  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  
  .rss-subscribe-btn {
    font-size: 0.85rem;
    padding: 5px 10px;
  }
}
.back-link {
  display: inline-block;
  margin-bottom: 2rem;
  color: #3477e3;
  text-decoration: none;
  font-weight: 500;
  padding: 6px 14px;
  border-radius: 7px;
  background: #e9f1ff;
  transition: background 0.2s;
}
.back-link:hover {
  background: #d6eaff;
}

/* RSS Feed Styles */
.rss-feed-container {
  margin-top: 2rem;
  border: 1px solid #e3e9f5;
  border-radius: 8px;
  background: #f7f8fa;
  padding: 1.2rem;
}

.rss-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid #e3e9f5;
}

.rss-title {
  font-size: 1.22rem;
  color: #4a6fa5;
  margin: 0;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.rss-link {
  color: #3477e3;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 4px 8px;
  border-radius: 4px;
  background: #e9f1ff;
  transition: background 0.2s;
}

.rss-link:hover {
  background: #d6eaff;
  text-decoration: none;
}

.rss-items {
  max-height: 300px;
  overflow-y: auto;
}

.rss-item {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #e9eef6;
}

.rss-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.rss-item-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 0.4rem;
  gap: 1rem;
}

.rss-item-title {
  color: #3477e3;
  text-decoration: none;
  font-weight: 500;
  font-size: 1.05em;
  line-height: 1.4;
  flex: 1;
  transition: color 0.18s;
}

.rss-item-title:hover {
  color: #17408b;
  text-decoration: underline;
}

.rss-item-date {
  color: #6a7c93;
  font-size: 0.85em;
  font-style: italic;
  white-space: nowrap;
  flex-shrink: 0;
}

.rss-item-description {
  color: #555;
  font-size: 0.95em;
  line-height: 1.5;
  margin: 0;
}

.rss-error {
  text-align: center;
  color: #d73027;
  padding: 1rem;
}

.rss-error a {
  color: #3477e3;
  text-decoration: none;
}

.rss-error a:hover {
  text-decoration: underline;
}

/* Custom scrollbar for RSS items */
.rss-items::-webkit-scrollbar {
  width: 6px;
  background: #fff;
  border-radius: 6px;
}

.rss-items::-webkit-scrollbar-thumb {
  background: #e9eef6;
  border-radius: 6px;
}

@media (max-width: 640px) {
  .rss-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  
  .rss-item-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.3rem;
  }
  
  .rss-item-date {
    white-space: normal;
  }
}
