/*
Theme Name: DUL Journal
Version: 1.0.0
Description: Clean technical journal theme for Oracle notes.
*/

:root {
  --text: #1f2933;
  --muted: #697386;
  --soft: #f6f8fb;
  --line: #e3e8ef;
  --accent: #0f766e;
  --accent-dark: #115e59;
  --code: #111827;
  --paper: #ffffff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  background: #f4f6f8;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  line-height: 1.72;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: var(--accent-dark);
  text-decoration: underline;
  text-decoration-thickness: 2px;
}

.site-header {
  background: #26364a;
  border-bottom: 4px solid var(--accent);
}

.wrap {
  width: min(1180px, calc(100% - 42px));
  margin: 0 auto;
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 76px;
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand-title {
  color: #fff;
  font-size: 24px;
  font-weight: 750;
  letter-spacing: 0;
}

.brand-subtitle {
  color: #c9d3df;
  font-size: 13px;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 14px;
}

.top-nav a {
  color: #e5edf6;
}

.top-nav a:hover {
  color: #fff;
}

.site-main {
  padding: 28px 0 54px;
}

.layout {
  display: grid;
  grid-template-columns: 292px minmax(0, 1fr);
  gap: 26px;
  align-items: start;
}

.content-panel,
.sidebar-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 4px;
}

.content-panel {
  padding: 26px 30px;
  min-width: 0;
}

.index-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 14px;
  margin-bottom: 6px;
  border-bottom: 2px solid #d8e0ea;
}

.page-heading {
  margin: 0;
  font-size: 25px;
  line-height: 1.25;
  letter-spacing: 0;
}

.index-count {
  color: var(--muted);
  font-size: 13px;
}

.post-list {
  display: grid;
  gap: 0;
}

.post-card {
  padding: 20px 0 18px;
  border-bottom: 1px solid var(--line);
}

.post-card:first-child {
  border-top: 0;
}

.post-card h2 {
  margin: 0 0 8px;
  font-size: 21px;
  line-height: 1.35;
  letter-spacing: 0;
  word-break: break-word;
}

.post-card h2 a {
  color: var(--text);
}

.post-card h2 a:hover {
  color: var(--accent);
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 13px;
}

.meta a {
  color: var(--muted);
}

.excerpt {
  margin: 0 0 8px;
  color: #4b5563;
  font-size: 15px;
  line-height: 1.68;
}

.postmetadata {
  color: var(--muted);
  font-size: 13px;
}

.postmetadata a {
  color: #4f718f;
}

.postmetadata .sep {
  padding: 0 7px;
  color: #a0acba;
}

.article {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 38px 42px;
  min-width: 0;
}

.article-title {
  margin: 0 0 12px;
  font-size: 34px;
  line-height: 1.25;
  letter-spacing: 0;
  word-break: break-word;
}

.article .meta {
  padding-bottom: 24px;
  margin-bottom: 30px;
  border-bottom: 1px solid var(--line);
}

.entry-content {
  font-size: 17px;
  line-height: 1.82;
  overflow-wrap: anywhere;
}

.entry-content > *:first-child {
  margin-top: 0;
}

.entry-content h2,
.entry-content h3,
.entry-content h4 {
  margin: 34px 0 14px;
  line-height: 1.35;
  letter-spacing: 0;
}

.entry-content h2 {
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
  font-size: 25px;
}

.entry-content h3 {
  font-size: 21px;
}

.entry-content p {
  margin: 0 0 18px;
  word-break: break-word;
}

.entry-content ul,
.entry-content ol {
  margin: 0 0 20px 1.4em;
  padding: 0;
}

.entry-content li + li {
  margin-top: 6px;
}

.entry-content pre {
  margin: 22px 0;
  padding: 18px 20px;
  overflow-x: auto;
  white-space: pre;
  color: #e5edf6;
  background: var(--code);
  border: 1px solid #243244;
  border-radius: 7px;
  font-size: 14px;
  line-height: 1.65;
}

.entry-content code,
.entry-content pre {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
}

.entry-content :not(pre) > code {
  padding: 0.12em 0.34em;
  color: #9f1239;
  background: #fff1f2;
  border: 1px solid #ffe4e6;
  border-radius: 4px;
  font-size: 0.92em;
}

.entry-content table {
  width: 100%;
  margin: 24px 0;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 14px;
  line-height: 1.55;
}

.entry-content th,
.entry-content td {
  padding: 9px 11px;
  border: 1px solid var(--line);
  vertical-align: top;
  overflow-wrap: anywhere;
}

.entry-content a {
  overflow-wrap: anywhere;
}

.entry-content hr {
  height: 1px;
  margin: 28px 0;
  background: var(--line);
  border: 0;
}

.entry-content .wp-caption,
.entry-content .aligncenter {
  max-width: 100%;
}

.entry-content iframe,
.entry-content embed,
.entry-content object {
  max-width: 100%;
}

.entry-content th {
  background: var(--soft);
  font-weight: 700;
}

.entry-content blockquote {
  margin: 24px 0;
  padding: 14px 18px;
  color: #465363;
  background: var(--soft);
  border-left: 4px solid var(--accent);
  border-radius: 0 6px 6px 0;
}

.entry-content img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 18px auto;
  border: 1px solid var(--line);
  border-radius: 6px;
}

.entry-content figure {
  margin: 24px 0;
}

.sidebar {
  display: grid;
  align-content: start;
  gap: 18px;
}

.sidebar-card {
  padding: 16px 18px;
}

.sidebar-card h3 {
  margin: 0 0 10px;
  padding-bottom: 7px;
  border-bottom: 1px solid var(--line);
  color: #26364a;
  font-size: 15px;
}

.sidebar-card ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.sidebar-card li + li {
  margin-top: 8px;
}

.sidebar-card a {
  color: #425b76;
}

.site-note p {
  margin: 0;
  color: #526171;
  font-size: 13px;
  line-height: 1.65;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tag-cloud a {
  display: inline-flex;
  padding: 3px 7px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 4px;
  font-size: 13px;
}

.search-form {
  display: flex;
  gap: 8px;
}

.search-field {
  min-width: 0;
  width: 100%;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  font: inherit;
}

.search-submit {
  padding: 9px 12px;
  color: #fff;
  background: var(--accent);
  border: 0;
  border-radius: 6px;
  font: inherit;
  cursor: pointer;
}

.pagination {
  display: flex;
  gap: 8px;
  margin-top: 28px;
}

.pagination .page-numbers {
  min-width: 34px;
  padding: 6px 10px;
  text-align: center;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 6px;
}

.pagination .current {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}

.site-footer {
  padding: 24px 0;
  color: var(--muted);
  background: #26364a;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: #c9d3df;
}

@media (max-width: 860px) {
  .wrap {
    width: min(100% - 28px, 1120px);
  }

  .site-header .wrap,
  .layout {
    display: block;
  }

  .top-nav {
    margin-top: 10px;
  }

  .content-panel,
  .article {
    padding: 20px;
  }

  .article-title {
    font-size: 28px;
  }

  .sidebar {
    margin-top: 22px;
  }
}
