/* ChartClock canvas: header, constrained shell, spacing. Overrides TT5 bleed. */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
}

body.chartclock-canvas {
  margin: 0;
  overflow-x: hidden;
  background: #0a0c0e;
  color: #f4f6f5;
  font-family: Lato, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 1.55;
}

body.chartclock-canvas a {
  color: #16d016;
}

body.chartclock-canvas img,
body.chartclock-canvas video,
body.chartclock-canvas iframe,
body.chartclock-canvas svg {
  max-width: 100%;
  height: auto;
}

.cc-header {
  position: sticky;
  top: 0;
  z-index: 2000;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  padding: 14px 24px;
  border-bottom: 1px solid #2a3138;
  background: rgba(10, 12, 14, 0.94);
  backdrop-filter: blur(12px);
}

.cc-logo {
  margin-right: auto;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #16d016 !important;
  text-decoration: none;
}

.cc-nav {
  flex: 1 1 auto;
}

.cc-nav .menu,
.cc-nav ul {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.cc-nav a {
  color: #c5ccc9 !important;
  text-decoration: none;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cc-nav a:hover,
.cc-nav .current-menu-item > a,
.cc-nav .current_page_item > a {
  color: #f4f6f5 !important;
}

.cc-header .cc-btn {
  flex: 0 0 auto;
}

.cc-shell {
  width: min(1080px, calc(100% - 40px));
  margin: 0 auto;
  padding: 40px 0 80px;
}

body.chartclock-canvas .alignfull,
body.chartclock-canvas .alignwide,
.cc-shell .alignfull,
.cc-shell .alignwide,
.cc-shell .wp-block-group.alignfull,
.cc-shell .wp-block-columns.alignwide {
  width: 100% !important;
  max-width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  left: auto !important;
  right: auto !important;
}

.cc-shell .wp-block-group,
.cc-shell .wp-block-columns {
  padding-left: 0 !important;
  padding-right: 0 !important;
}

body.chartclock-canvas .has-global-padding,
body.chartclock-canvas .is-layout-constrained,
body.chartclock-canvas .wp-site-blocks {
  padding: 0 !important;
  max-width: 100% !important;
}

.cc-shell h1,
.cc-shell h2,
.cc-shell h3,
.cc-shell p,
.cc-shell .wp-block-buttons,
.cc-shell .wp-block-columns,
.cc-shell .wp-block-group,
.cc-shell .chart-clock,
.cc-shell video,
.cc-shell .cc-account {
  max-width: 100%;
}

.cc-shell .wp-block-image {
  margin: 12px 0 28px;
}

.cc-shell .wp-block-image img {
  width: 100%;
  height: auto;
  border-radius: 16px;
}

.cc-shell > p {
  max-width: 42rem;
}

.cc-shell h1 {
  margin: 0 0 16px;
  font-size: clamp(1.7rem, 4.2vw, 2.6rem);
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.cc-shell h2 {
  margin: 0 0 12px;
  font-size: clamp(1.35rem, 2.6vw, 1.75rem);
}

.cc-shell h3 {
  margin: 0 0 10px;
  font-size: 1.15rem;
}

.cc-shell p {
  margin: 0 0 16px;
  color: #c5ccc9;
}

.cc-shell .wp-block-group {
  margin: 0 0 36px;
}

.cc-shell .wp-block-group > * + * {
  margin-top: 16px;
}

.cc-shell .wp-block-columns {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin: 0 0 40px;
}

.cc-shell .wp-block-column {
  flex: 1 1 280px;
  min-width: 0;
  margin: 0 !important;
}

.cc-shell .wp-block-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 20px 0 28px;
}

.cc-btn,
body.chartclock-canvas .wp-block-button__link {
  display: inline-block;
  padding: 12px 18px;
  background: #16d016;
  color: #0a0c0e !important;
  border: 0;
  border-radius: 8px;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  cursor: pointer;
}

.cc-btn--ghost,
body.chartclock-canvas .wp-block-button.is-style-outline .wp-block-button__link {
  background: transparent;
  color: #f4f6f5 !important;
  border: 1px solid #2a3138;
}

.cc-card,
body.chartclock-canvas .wp-block-column.has-background {
  background: #1a1f26;
  border: 1px solid #2a3138;
  border-radius: 16px;
  padding: 24px !important;
}

.cc-kicker,
.cc-shell .has-text-color[style*="16d016"] {
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

body.chartclock-canvas .chart-clock {
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 28px 0 36px;
  overflow: hidden;
  border: 1px solid #2a3138;
  border-radius: 12px;
}

body.chartclock-canvas .chart-clock--v1 {
  min-height: 0;
}

.cc-footer {
  width: min(1080px, calc(100% - 40px));
  margin: 0 auto;
  padding: 28px 0 48px;
  border-top: 1px solid #2a3138;
  color: #9aa3a0;
  font-size: 14px;
}

.cc-footer p {
  margin: 0 0 8px;
}

.cc-footer a {
  margin-right: 16px;
  color: #c5ccc9;
  text-decoration: none;
}

body.chartclock-chrome #header,
body.chartclock-chrome #headerimg,
body.chartclock-chrome #page > hr,
body.chartclock-chrome .bn-community-menu,
body.chartclock-chrome header.wp-block-template-part,
body.chartclock-chrome footer.wp-block-template-part {
  display: none !important;
}

body.chartclock-chrome {
  padding-top: 58px;
}

body.chartclock-chrome .cc-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
}

body.admin-bar.chartclock-chrome {
  padding-top: 90px;
}

body.admin-bar.chartclock-chrome .cc-header {
  top: 32px;
}

body.chartclock-chrome .cc-footer {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 28px 24px 48px;
  background: #0a0c0e;
}

.cc-account {
  max-width: 720px;
  margin: 0 auto;
  padding: 8px 0 48px;
}

.cc-account .cc-card,
.cc-account section {
  margin: 24px 0;
  padding: 24px;
  background: #1a1f26;
  border: 1px solid #2a3138;
  border-radius: 16px;
}

.cc-key {
  width: 100%;
  max-width: 100%;
  padding: 10px 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  background: #12151a;
  color: #16d016;
  border: 1px solid #2a3138;
  border-radius: 8px;
}

.cc-banner {
  background: rgba(22, 208, 22, 0.12);
  border: 1px solid #16d016;
  border-radius: 8px;
  padding: 12px 16px;
}

@media (max-width: 720px) {
  .cc-header {
    padding: 12px 16px;
  }

  .cc-nav {
    order: 3;
    flex: 1 0 100%;
  }

  .cc-shell {
    width: calc(100% - 32px);
    padding-top: 28px;
  }
}
