/* Giá Ca Cao — frontend shortcode */
.gcc-wrap {
  --gcc-brown: #4a3228;
  --gcc-cream: #faf6f1;
  --gcc-line: rgba(74, 50, 40, 0.14);
  --gcc-accent: #7a4e32;
  font-family: inherit;
  max-width: 960px;
  margin: 1.25rem auto;
}
.gcc-card {
  background: var(--gcc-cream);
  border: 1px solid var(--gcc-line);
  border-radius: 16px;
  padding: clamp(18px, 3vw, 26px);
  box-shadow: 0 8px 30px rgba(45, 30, 20, 0.08);
}
.gcc-head {
  margin-bottom: 1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--gcc-line);
}
.gcc-head h2 {
  margin: 0 0 0.35rem;
  font-size: clamp(1.15rem, 2.4vw, 1.35rem);
  font-weight: 800;
  color: var(--gcc-brown);
  letter-spacing: -0.02em;
}
.gcc-meta {
  margin: 0;
  font-size: 0.85rem;
  font-weight: 600;
  color: #6b5b50;
}

.gcc-meta--empty {
  font-weight: 500;
  font-style: italic;
  color: #8a7b72;
}

/* Mốc cập nhật: giờ + thứ + ngày tháng năm */
.gcc-updated {
  margin-top: 0.35rem;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--gcc-line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.75) 0%, rgba(250, 246, 241, 0.95) 100%);
}

.gcc-updated__lead {
  margin: 0 0 6px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #7a6a62;
}

.gcc-updated__time {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 14px;
  margin: 0;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--gcc-brown);
}

.gcc-updated__clock {
  font-size: clamp(1.35rem, 3.2vw, 1.75rem);
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.03em;
  color: var(--gcc-accent);
  line-height: 1;
}

.gcc-updated__weekday {
  font-weight: 700;
  color: #5c4a42;
}

.gcc-updated__weekday::after {
  content: '·';
  margin-left: 10px;
  font-weight: 800;
  color: rgba(74, 50, 40, 0.35);
}

.gcc-updated__date {
  flex-basis: 100%;
  font-size: 0.9rem;
  font-weight: 600;
  color: #5c534d;
}

@media (min-width: 520px) {
  .gcc-updated__time {
    flex-wrap: nowrap;
  }

  .gcc-updated__date {
    flex-basis: auto;
  }

  .gcc-updated__weekday::after {
    content: '';
    margin: 0;
  }

  .gcc-updated__date::before {
    content: '·';
    margin-right: 10px;
    font-weight: 800;
    color: rgba(74, 50, 40, 0.35);
  }
}

.gcc-card--futures {
  border-top: 4px solid var(--gcc-accent);
  box-shadow: 0 10px 36px rgba(45, 30, 20, 0.1);
}

.gcc-section--futures {
  margin-top: 0.25rem;
}

html[data-theme="dark"] .gcc-updated {
  background: rgba(48, 38, 32, 0.85);
  border-color: rgba(255, 255, 255, 0.1);
}

html[data-theme="dark"] .gcc-updated__lead {
  color: #c4b8b0;
}

html[data-theme="dark"] .gcc-updated__clock {
  color: #e8b896;
}

html[data-theme="dark"] .gcc-updated__weekday,
html[data-theme="dark"] .gcc-updated__date {
  color: #d4cbc4;
}
.gcc-note {
  margin: 0 0 1rem;
  font-size: 0.88rem;
  color: #5c534d;
  line-height: 1.55;
}
.gcc-tables {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.gcc-sub {
  margin: 0 0 0.65rem;
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--gcc-accent);
}
.gcc-grid {
  overflow-x: auto;
  border-radius: 12px;
  border: 1px solid var(--gcc-line);
}
.gcc-grid table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  min-width: 520px;
}
.gcc-grid th,
.gcc-grid td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--gcc-line);
}
.gcc-grid thead th {
  background: var(--gcc-brown);
  color: #fff;
  font-weight: 700;
  white-space: nowrap;
}
.gcc-grid tbody tr:last-child td {
  border-bottom: 0;
}
.gcc-grid tbody tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.65);
}
.gcc-num {
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}
.gcc-delta-pos {
  color: #0f6b3a;
}
.gcc-delta-neg {
  color: #9b1c1c;
}
.gcc-delta-zero {
  color: #5c534d;
}
.gcc-foot {
  margin-top: 1rem;
  font-size: 0.78rem;
  color: #7a6f68;
}

/* SEO: đoạn mô tả khi seo_text="1" */
.gcc-seo-block {
  margin: 0 0 1.25rem;
  padding: 1rem 1.1rem 1.05rem;
  border-radius: 12px;
  border: 1px solid var(--gcc-line);
  background: rgba(255, 255, 255, 0.55);
}
.gcc-seo-block__title {
  margin: 0 0 0.65rem;
  font-size: clamp(1.02rem, 2.2vw, 1.18rem);
  font-weight: 800;
  color: var(--gcc-brown);
  letter-spacing: -0.02em;
  line-height: 1.3;
}
.gcc-seo-block__sub {
  margin: 1rem 0 0.45rem;
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--gcc-accent);
}
.gcc-seo-block__p {
  margin: 0 0 0.5rem;
  font-size: 0.88rem;
  line-height: 1.65;
  color: #4a433d;
}
.gcc-seo-block__p:last-child {
  margin-bottom: 0;
}

html[data-theme="dark"] .gcc-seo-block {
  background: rgba(40, 32, 28, 0.75);
  border-color: rgba(255, 255, 255, 0.12);
}
html[data-theme="dark"] .gcc-seo-block__title {
  color: #f0e6df;
}
html[data-theme="dark"] .gcc-seo-block__sub {
  color: #e8b896;
}
html[data-theme="dark"] .gcc-seo-block__p {
  color: #d4cbc4;
}

/* Chế độ tối: toàn khối shortcode (trùng selector với theme data-theme trên <html>) */
[data-theme="dark"] .gcc-wrap,
html[data-theme="dark"] .gcc-wrap {
  --gcc-brown: #efe8e3;
  --gcc-cream: #161c18;
  --gcc-line: rgba(255, 255, 255, 0.12);
  --gcc-accent: #e0b080;
}

[data-theme="dark"] .gcc-card,
html[data-theme="dark"] .gcc-card {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] .gcc-meta,
html[data-theme="dark"] .gcc-meta {
  color: #b8b0a8;
}

[data-theme="dark"] .gcc-note,
html[data-theme="dark"] .gcc-note {
  color: #b5aea6;
}

[data-theme="dark"] .gcc-grid tbody td,
html[data-theme="dark"] .gcc-grid tbody td {
  color: #dce4df;
}

[data-theme="dark"] .gcc-grid tbody tr:nth-child(even),
html[data-theme="dark"] .gcc-grid tbody tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.04);
}

[data-theme="dark"] .gcc-foot,
html[data-theme="dark"] .gcc-foot {
  color: #9a9a94;
}

[data-theme="dark"] .gcc-delta-zero,
html[data-theme="dark"] .gcc-delta-zero {
  color: #b0c4b8;
}
