/*
Theme Name: Диджитал колледж
Description: Публичный сайт модульной платформы для СПО.
Version: 1.1.0
Text Domain: dc-site
*/

:root {
  --dc-paper: #f6f7f9;
  --dc-white: #fff;
  --dc-ink: #192435;
  --dc-muted: #526071;
  --dc-line: #d1d8e2;
  --dc-blue: #204aab;
  --dc-blue-hover: #173982;
  --dc-wash: #e9effa;
  --dc-green: #176049;
  --dc-width: 1160px;
}

html { scroll-padding-top: 1.5rem; }
body { margin: 0; background: var(--dc-paper); color: var(--dc-ink); }
:where(a, button):focus-visible { outline: 3px solid var(--dc-blue); outline-offset: 4px; }
.dc-shell { width: min(var(--dc-width), calc(100% - 4rem)); margin-inline: auto; }
.dc-header { background: var(--dc-white); border-bottom: 1px solid var(--dc-line); }
.dc-header .dc-shell, .dc-footer .dc-shell { display: flex; gap: 1.5rem; align-items: center; justify-content: space-between; }
.dc-header .dc-shell { min-height: 68px; padding-block: .65rem; box-sizing: border-box; }
.dc-brand { display: inline-flex; align-items: center; gap: .6rem; color: inherit; text-decoration: none; font-weight: 720; }
.dc-brand img { width: 30px; height: 30px; object-fit: contain; }
.dc-nav, .dc-header-actions, .dc-footer-links { display: flex; gap: 1.3rem; align-items: center; flex-wrap: wrap; }
.dc-nav a, .dc-header-actions > a, .dc-footer a { color: inherit; text-decoration: none; }
.dc-nav a:hover, .dc-footer a:hover { text-decoration: underline; text-underline-offset: .2em; }

.dc-button, .wp-block-button > .wp-block-button__link.wp-element-button {
  border: 1px solid var(--dc-blue);
  border-radius: .35rem;
  padding: .65rem .95rem;
  font-weight: 650;
  background: var(--dc-blue);
  color: var(--dc-white);
  text-decoration: none;
}
.dc-header-actions > .dc-button { color: var(--dc-white); }
.dc-button:hover, .wp-block-button > .wp-block-button__link.wp-element-button:hover {
  background: var(--dc-blue-hover);
  border-color: var(--dc-blue-hover);
  color: var(--dc-white);
}
.wp-block-button.is-style-outline > .wp-block-button__link.wp-element-button {
  background: transparent;
  border-color: var(--dc-blue);
  color: var(--dc-blue);
}
.wp-block-button.is-style-outline > .wp-block-button__link.wp-element-button:hover {
  background: var(--dc-wash);
  border-color: var(--dc-blue-hover);
  color: var(--dc-blue-hover);
}

.dc-hero { background: var(--dc-white); border-bottom: 1px solid var(--dc-line); }
.dc-hero-inner {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  align-items: center;
  gap: clamp(1.8rem, 5vw, 4.5rem);
  padding-block: clamp(2.8rem, 6vw, 5rem);
}
.dc-hero h1, .dc-page h1 {
  font-size: clamp(2.5rem, 6vw, 5.2rem);
  line-height: 1.03;
  letter-spacing: -.058em;
  margin: 0;
  overflow-wrap: break-word;
}
.dc-hero-copy > p { color: var(--dc-muted); max-width: 23ch; font-size: clamp(1.125rem, 2.1vw, 1.46rem); line-height: 1.4; margin: .95rem 0 1.6rem; }
.dc-hero .wp-block-buttons, .dc-module .wp-block-buttons { gap: .65rem; }

.dc-product {
  margin: 0;
  min-width: 0;
  background: var(--dc-paper);
  border: 1px solid var(--dc-line);
  border-top: 3px solid var(--dc-blue);
  border-radius: .35rem;
}
.dc-product-heading {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: .25rem 1rem;
  padding: 1rem 1.25rem;
  background: var(--dc-white);
}
.dc-product-name { font-weight: 720; }
.dc-product-campaign, .dc-product figcaption { font-size: .875rem; color: var(--dc-muted); }
.dc-product-table { width: 100%; border-collapse: collapse; background: var(--dc-white); text-align: left; }
.dc-product-table th, .dc-product-table td { padding: .65rem .45rem; border-top: 1px solid var(--dc-line); }
.dc-product-table :is(th, td):first-child { padding-inline-start: 1.25rem; }
.dc-product-table :is(th, td):last-child { padding-inline-end: 1.25rem; }
.dc-product-table th { background: var(--dc-paper); color: var(--dc-muted); font-size: .875rem; font-weight: 650; }
.dc-product-table td { font-size: .94rem; }
.dc-product-table td:nth-child(2) { font-variant-numeric: tabular-nums; }
.dc-product figcaption { padding: .65rem 1.25rem; border-top: 1px solid var(--dc-line); }

.dc-board, .dc-news, .dc-page { padding-block: clamp(2rem, 5vw, 3.8rem); }
.dc-board h2, .dc-news h2 { margin: 0 0 1.3rem; font-size: clamp(1.65rem, 3vw, 2.45rem); letter-spacing: -.04em; line-height: 1.16; }
.dc-module-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 1.5rem; }
.dc-module { min-width: 0; border-top: 1px solid var(--dc-line); padding: .95rem 0 1.05rem; }
.dc-module-feature {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: .15rem 2rem;
  padding-block: 1.25rem 1.5rem;
  border-top: 2px solid var(--dc-ink);
}
.dc-module-feature > :not(.wp-block-buttons) { grid-column: 1; }
.dc-module-feature > .wp-block-buttons { grid-column: 2; grid-row: 1 / span 3; align-self: center; }
.dc-module h3 { margin: 0; font-size: 1.12rem; letter-spacing: -.02em; line-height: 1.3; }
.dc-module-feature h3 { font-size: clamp(1.4rem, 2.5vw, 1.95rem); }
.dc-module p { margin: .3rem 0 0; color: var(--dc-muted); }
.dc-module .dc-status { font-size: .875rem; }
.dc-module-feature .dc-status { color: var(--dc-green); font-weight: 680; }

.dc-page { min-height: 45vh; }
.dc-page h1 { font-size: clamp(2.3rem, 5vw, 4rem); }
.dc-page .wp-block-post-content { max-width: 49rem; }
.dc-news ul { padding: 0; list-style: none; }
.dc-news li { padding: .65rem 0; border-top: 1px solid var(--dc-line); }
.dc-footer { background: var(--dc-white); border-top: 1px solid var(--dc-line); padding-block: 2rem; }
.dc-footer p { margin: .4rem 0 0; color: var(--dc-muted); }
.dc-footer .dc-shell { align-items: flex-start; }
.dc-footer-links a { padding-block: .25rem; }

@media (max-width: 865px) {
  .dc-shell { width: calc(100% - 2rem); }
  .dc-header .dc-shell { flex-wrap: wrap; gap: .7rem; }
  .dc-nav { order: 3; width: 100%; padding-bottom: .25rem; }
  .dc-hero-inner { grid-template-columns: minmax(0, 1fr); }
  .dc-hero-copy > p { max-width: 31ch; }
  .dc-module-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 1rem; }
  .dc-module-feature { display: block; }
  .dc-module-feature > .wp-block-buttons { margin-top: .9rem; }
}

@media (max-width: 480px) {
  .dc-header-actions, .dc-nav, .dc-footer-links { gap: .65rem; }
  .dc-header .dc-shell, .dc-footer .dc-shell { flex-direction: column; align-items: flex-start; }
  .dc-nav { order: 0; }
  .dc-product-heading, .dc-product figcaption { padding-inline: .7rem; }
  .dc-product-table :is(th, td):first-child { padding-inline-start: .7rem; }
  .dc-product-table :is(th, td):last-child { padding-inline-end: .7rem; }
}
