/*
Theme Name: ClickMe Core
Theme URI: https://click-me.com.ua/
Author: ClickMe
Description: Быстрая современная тема для ClickMe. Совместима с Elementor и рассчитана на сервисные страницы, статьи и блог.
Version: 1.0.0
Text Domain: clickme-core
Requires at least: 6.0
Requires PHP: 7.4
License: GPL-2.0-or-later
*/

:root {
  --cm-ink: #121a2b;
  --cm-ink-2: #26334a;
  --cm-muted: #64738a;
  --cm-line: #dfe7f1;
  --cm-cloud: #f5f8fc;
  --cm-paper: #ffffff;
  --cm-orange: #ff6847;
  --cm-orange-deep: #e94f32;
  --cm-blue: #4267e8;
  --cm-cyan: #40b9d7;
  --cm-shadow: 0 18px 52px rgba(28, 47, 77, .10);
  --cm-radius: 22px;
  --cm-content: 760px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--cm-ink);
  background: var(--cm-cloud);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; }
a { color: inherit; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); border: 0; }
.screen-reader-text:focus { clip: auto; width: auto; height: auto; left: 14px; top: 14px; z-index: 9999; padding: 10px 14px; color: var(--cm-ink); background: #fff; border-radius: 8px; }
.site-shell { overflow: clip; }
.cm-container { width: min(1180px, calc(100% - 40px)); margin-inline: auto; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.88); border-bottom: 1px solid rgba(223,231,241,.86); backdrop-filter: blur(14px); }
.site-header__bar { min-height: 78px; display: flex; gap: 24px; align-items: center; justify-content: space-between; }
.site-branding { flex: 0 0 auto; min-width: 0; }
.custom-logo-link { display: inline-flex; align-items: center; }
.custom-logo { display: block; max-height: 42px; width: auto; }
.site-title { color: var(--cm-ink); font-weight: 850; font-size: 22px; letter-spacing: -.055em; text-decoration: none; }
.site-description { display: none; }
.primary-nav { margin-left: auto; }
.primary-nav ul { display: flex; align-items: center; gap: 4px; list-style: none; padding: 0; margin: 0; }
.primary-nav a { display: block; padding: 10px 12px; color: var(--cm-ink-2); font-size: 14px; font-weight: 700; text-decoration: none; border-radius: 10px; transition: color .2s ease, background .2s ease; }
.primary-nav a:hover, .primary-nav .current-menu-item > a { color: var(--cm-orange-deep); background: #fff2ee; }
.header-actions { display: flex; gap: 10px; align-items: center; }
.cm-button { display: inline-flex; min-height: 44px; align-items: center; justify-content: center; gap: 8px; padding: 11px 18px; color: #fff; background: linear-gradient(125deg, var(--cm-orange), #fb4d67); border: 0; border-radius: 12px; box-shadow: 0 10px 20px rgba(243, 81, 69, .22); font-size: 14px; font-weight: 800; line-height: 1; text-decoration: none; transition: transform .2s ease, box-shadow .2s ease; }
.cm-button:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 14px 24px rgba(243,81,69,.28); }
.menu-toggle { display: none; padding: 10px; color: var(--cm-ink); border: 1px solid var(--cm-line); background: #fff; border-radius: 10px; }
.menu-toggle svg { display: block; width: 21px; height: 21px; }

/* Front page */
.cm-hero { position: relative; isolation: isolate; padding: clamp(56px, 8vw, 104px) 0 72px; background: linear-gradient(135deg, #f7fbff 0%, #eef5ff 50%, #fff5f0 100%); }
.cm-hero::before, .cm-hero::after { position: absolute; content: ""; z-index: -1; width: 460px; height: 460px; border-radius: 50%; filter: blur(10px); opacity: .72; }
.cm-hero::before { top: -250px; right: -100px; background: radial-gradient(circle, rgba(64,185,215,.23), transparent 65%); }
.cm-hero::after { bottom: -330px; left: -160px; background: radial-gradient(circle, rgba(255,104,71,.20), transparent 65%); }
.cm-hero__grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 54px; align-items: center; }
.cm-eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px; color: #35557d; background: rgba(255,255,255,.72); border: 1px solid rgba(210,224,239,.9); border-radius: 999px; font-size: 12px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.cm-eyebrow::before { width: 7px; height: 7px; content: ""; background: #3dcc81; border-radius: 50%; box-shadow: 0 0 0 4px rgba(61,204,129,.14); }
.cm-hero h1 { max-width: 720px; margin: 18px 0; color: var(--cm-ink); font-size: clamp(38px, 5.2vw, 68px); font-weight: 850; letter-spacing: -.07em; line-height: 1.03; }
.cm-hero h1 em { color: var(--cm-orange-deep); font-style: normal; }
.cm-hero__lead { max-width: 590px; margin: 0 0 27px; color: var(--cm-ink-2); font-size: clamp(17px, 2vw, 20px); line-height: 1.55; }
.cm-hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.cm-button--light { color: var(--cm-ink-2); background: rgba(255,255,255,.86); box-shadow: 0 7px 18px rgba(45,66,92,.09); }
.cm-button--light:hover { color: var(--cm-orange-deep); }
.cm-platform-panel { padding: 18px; background: rgba(255,255,255,.78); border: 1px solid rgba(219,229,240,.95); border-radius: 28px; box-shadow: 0 24px 52px rgba(39,67,102,.13); }
.cm-platform-panel__top { display: flex; align-items: center; justify-content: space-between; padding: 4px 5px 15px; color: var(--cm-muted); font-size: 13px; font-weight: 750; }
.cm-platform-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.cm-platform { min-height: 112px; display: flex; flex-direction: column; justify-content: space-between; padding: 15px; color: var(--cm-ink); background: #fff; border: 1px solid #e5ebf3; border-radius: 17px; text-decoration: none; transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease; }
.cm-platform:hover { color: var(--cm-ink); border-color: transparent; box-shadow: 0 12px 24px rgba(24,45,75,.12); transform: translateY(-3px); }
.cm-platform__mark { width: 35px; height: 35px; display: grid; place-items: center; color: #fff; background: var(--platform, var(--cm-blue)); border-radius: 11px; font-size: 15px; font-weight: 900; }
.cm-platform strong { font-size: 15px; letter-spacing: -.02em; }
.cm-platform small { color: var(--cm-muted); font-size: 11px; }
.cm-platform--instagram { --platform: linear-gradient(135deg,#fdc24e,#f24d79,#7a47d8); }
.cm-platform--tiktok { --platform: #151720; }
.cm-platform--telegram { --platform: #35a9e9; }
.cm-platform--youtube { --platform: #ff424b; }
.cm-front-content { padding: 54px 0 84px; }

/* Pages and Elementor canvas */
.site-main { min-height: 45vh; }
.cm-page-header { padding: 46px 0 26px; background: linear-gradient(135deg, #f7fbff, #fff8f4); border-bottom: 1px solid #e7eef6; }
.cm-page-header h1 { max-width: 900px; margin: 0; font-size: clamp(32px, 4vw, 52px); font-weight: 850; letter-spacing: -.06em; line-height: 1.08; }
.cm-page-content { padding: 44px 0 76px; }
.elementor-location-header, .elementor-location-footer { width: 100%; }
.elementor-page .cm-page-content { padding: 0; }

/* Designed text: pages and long-form articles */
.entry-content { max-width: var(--cm-content); color: #3f4e65; font-size: 18px; line-height: 1.82; }
.entry-content > *:first-child { margin-top: 0; }
.entry-content p { margin: 0 0 1.42em; }
.entry-content h2, .entry-content h3, .entry-content h4 { color: var(--cm-ink); font-weight: 840; letter-spacing: -.045em; line-height: 1.16; scroll-margin-top: 105px; }
.entry-content h2 { margin: 2.15em 0 .72em; padding-bottom: .45em; font-size: clamp(27px, 3.6vw, 38px); border-bottom: 1px solid var(--cm-line); }
.entry-content h3 { margin: 1.8em 0 .65em; font-size: clamp(22px, 2.7vw, 29px); }
.entry-content h4 { margin: 1.45em 0 .5em; font-size: 20px; }
.entry-content a { color: var(--cm-orange-deep); font-weight: 700; text-decoration-color: rgba(233,79,50,.35); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
.entry-content a:hover { color: #b93c29; text-decoration-color: currentColor; }
.entry-content ul, .entry-content ol { margin: 0 0 1.6em; padding-left: 1.35em; }
.entry-content li { margin: .46em 0; padding-left: .24em; }
.entry-content li::marker { color: var(--cm-orange); font-weight: 800; }
.entry-content blockquote { position: relative; margin: 2em 0; padding: 25px 28px 25px 30px; color: #283850; background: linear-gradient(120deg, #fff8f4, #fff); border: 1px solid #ffe1d7; border-radius: 0 18px 18px 0; border-left: 5px solid var(--cm-orange); font-size: 20px; font-weight: 650; line-height: 1.58; }
.entry-content blockquote p:last-child { margin-bottom: 0; }
.entry-content figure { margin: 2em 0; }
.entry-content figcaption { margin-top: 8px; color: var(--cm-muted); font-size: 13px; text-align: center; }
.entry-content img { border-radius: 16px; }
.entry-content table { width: 100%; margin: 1.8em 0; border-collapse: separate; border-spacing: 0; overflow: hidden; background: #fff; border: 1px solid var(--cm-line); border-radius: 14px; font-size: 15px; }
.entry-content th, .entry-content td { padding: 13px 15px; text-align: left; border-bottom: 1px solid var(--cm-line); }
.entry-content th { color: var(--cm-ink); background: #f6f9fd; font-size: 13px; }
.entry-content tr:last-child td { border-bottom: 0; }
.entry-content code { padding: .16em .36em; color: #b63f2b; background: #fff1ec; border-radius: 5px; font-size: .86em; }
.entry-content pre { padding: 18px; overflow: auto; color: #eaf0fa; background: #172034; border-radius: 14px; }
.entry-content pre code { padding: 0; color: inherit; background: transparent; }

/* Blog and archive */
.cm-archive-hero { padding: 52px 0 35px; background: radial-gradient(circle at 85% 0, #e4f4fc 0, transparent 35%), #f7faff; border-bottom: 1px solid var(--cm-line); }
.cm-kicker { margin: 0 0 9px; color: var(--cm-orange-deep); font-size: 12px; font-weight: 850; letter-spacing: .11em; text-transform: uppercase; }
.cm-archive-hero h1 { margin: 0; font-size: clamp(36px, 5vw, 57px); font-weight: 850; letter-spacing: -.065em; line-height: 1.05; }
.cm-archive-description { max-width: 650px; margin: 15px 0 0; color: var(--cm-muted); font-size: 17px; }
.cm-archive { padding: 44px 0 82px; }
.cm-post-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 24px; }
.cm-post-card { min-width: 0; overflow: hidden; background: var(--cm-paper); border: 1px solid #e4ebf3; border-radius: 20px; box-shadow: 0 8px 22px rgba(40,58,84,.045); transition: transform .22s ease, box-shadow .22s ease; }
.cm-post-card:hover { transform: translateY(-5px); box-shadow: var(--cm-shadow); }
.cm-post-card__image { display: block; overflow: hidden; aspect-ratio: 1.72 / 1; background: linear-gradient(135deg,#eaf2fb,#fff3ed); }
.cm-post-card__image img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.cm-post-card:hover .cm-post-card__image img { transform: scale(1.045); }
.cm-post-card__placeholder { display: grid; width: 100%; height: 100%; place-items: center; color: rgba(66,103,232,.55); font-size: 35px; font-weight: 900; }
.cm-post-card__body { padding: 19px 20px 21px; }
.cm-post-card__meta, .cm-post-meta { display: flex; flex-wrap: wrap; gap: 7px 12px; color: var(--cm-muted); font-size: 12px; font-weight: 650; }
.cm-post-card__meta a { color: var(--cm-orange-deep); text-decoration: none; }
.cm-post-card h2 { margin: 10px 0 9px; font-size: 21px; font-weight: 830; letter-spacing: -.04em; line-height: 1.18; }
.cm-post-card h2 a { color: var(--cm-ink); text-decoration: none; }
.cm-post-card h2 a:hover { color: var(--cm-orange-deep); }
.cm-post-card__excerpt { margin: 0; color: var(--cm-muted); font-size: 14px; line-height: 1.56; }
.cm-read-more { display: inline-flex; margin-top: 14px; color: var(--cm-orange-deep); font-size: 13px; font-weight: 800; text-decoration: none; }
.cm-read-more::after { margin-left: 7px; content: "→"; transition: transform .2s; }
.cm-read-more:hover::after { transform: translateX(4px); }
.navigation.pagination { display: flex; justify-content: center; margin-top: 40px; }
.nav-links { display: flex; gap: 7px; }
.page-numbers { display: grid; min-width: 40px; height: 40px; place-items: center; padding: 0 10px; color: var(--cm-ink-2); background: #fff; border: 1px solid var(--cm-line); border-radius: 10px; font-size: 14px; font-weight: 750; text-decoration: none; }
.page-numbers.current, .page-numbers:hover { color: #fff; background: var(--cm-orange); border-color: var(--cm-orange); }

/* Single post */
.cm-single { padding: 45px 0 80px; }
.cm-single__layout { display: grid; grid-template-columns: minmax(0, var(--cm-content)) 270px; gap: 68px; align-items: start; justify-content: space-between; }
.cm-single__header { margin-bottom: 28px; }
.cm-single__category { color: var(--cm-orange-deep); font-size: 12px; font-weight: 850; letter-spacing: .1em; text-decoration: none; text-transform: uppercase; }
.cm-single__title { margin: 10px 0 16px; color: var(--cm-ink); font-size: clamp(34px, 5vw, 54px); font-weight: 850; letter-spacing: -.065em; line-height: 1.06; }
.cm-featured-image { margin: 0 0 31px; overflow: hidden; border-radius: 20px; box-shadow: var(--cm-shadow); }
.cm-featured-image img { display: block; width: 100%; }
.cm-author-box { display: flex; gap: 15px; align-items: center; margin-top: 44px; padding: 18px; background: #f5f8fc; border: 1px solid var(--cm-line); border-radius: 16px; }
.cm-author-box__avatar img { display: block; border-radius: 50%; }
.cm-author-box__label { display: block; margin-bottom: 2px; color: var(--cm-muted); font-size: 12px; }
.cm-author-box__name { color: var(--cm-ink); font-size: 15px; font-weight: 850; text-decoration: none; }
.cm-author-box__bio { margin: 5px 0 0; color: var(--cm-muted); font-size: 13px; line-height: 1.45; }
.cm-sidebar { position: sticky; top: 100px; }
.cm-sidebar__title { margin: 0 0 12px; font-size: 14px; font-weight: 850; letter-spacing: .02em; }
.cm-sidebar .wp-block-latest-posts, .cm-sidebar ul { padding: 0; margin: 0; list-style: none; }
.cm-sidebar li { padding: 12px 0; border-bottom: 1px solid var(--cm-line); }
.cm-sidebar a { color: var(--cm-ink-2); font-size: 14px; font-weight: 700; line-height: 1.35; text-decoration: none; }
.cm-sidebar a:hover { color: var(--cm-orange-deep); }

/* Search, forms, comments */
.search-form { display: flex; gap: 8px; }
.search-field, input[type="text"], input[type="email"], input[type="url"], input[type="search"], textarea { width: 100%; padding: 11px 13px; color: var(--cm-ink); background: #fff; border: 1px solid #cfddea; border-radius: 10px; outline: none; transition: border-color .2s, box-shadow .2s; }
.search-field:focus, input:focus, textarea:focus { border-color: var(--cm-blue); box-shadow: 0 0 0 3px rgba(66,103,232,.12); }
.search-submit, input[type="submit"] { padding: 10px 14px; color: #fff; background: var(--cm-blue); border: 0; border-radius: 10px; font-weight: 800; }
.comment-respond, .comments-area { margin-top: 44px; padding-top: 30px; border-top: 1px solid var(--cm-line); }
.comment-list { padding: 0; list-style: none; }
.comment-body { padding: 18px 0; border-bottom: 1px solid var(--cm-line); }
.comment-author .avatar { margin-right: 8px; vertical-align: middle; border-radius: 50%; }

/* Footer */
.site-footer { color: #cdd7e7; background: #121a2b; }
.site-footer__main { display: grid; grid-template-columns: 1.2fr .8fr .8fr; gap: 38px; padding: 55px 0 35px; }
.site-footer__brand { max-width: 370px; }
.site-footer .site-title { color: #fff; }
.site-footer p { color: #9fadc2; font-size: 14px; }
.site-footer h2 { margin: 0 0 13px; color: #fff; font-size: 14px; font-weight: 800; }
.site-footer ul { margin: 0; padding: 0; list-style: none; }
.site-footer li { margin: 8px 0; }
.site-footer a { color: #bfcadd; font-size: 14px; text-decoration: none; }
.site-footer a:hover { color: #fff; }
.site-footer__bottom { display: flex; justify-content: space-between; gap: 20px; padding: 18px 0; color: #8492a8; border-top: 1px solid rgba(255,255,255,.10); font-size: 12px; }
.cm-to-top { position: fixed; right: 20px; bottom: 20px; z-index: 30; width: 44px; height: 44px; color: #fff; background: var(--cm-orange); border: 0; border-radius: 50%; box-shadow: 0 10px 24px rgba(233,79,50,.3); opacity: 0; pointer-events: none; transform: translateY(10px); transition: opacity .2s, transform .2s; }
.cm-to-top.is-visible { opacity: 1; pointer-events: auto; transform: translateY(0); }

@media (max-width: 900px) {
  .site-header__bar { min-height: 68px; }
  .menu-toggle { display: grid; place-items: center; }
  .primary-nav { position: absolute; top: calc(100% + 1px); right: 20px; left: 20px; display: none; padding: 10px; background: rgba(255,255,255,.98); border: 1px solid var(--cm-line); border-radius: 15px; box-shadow: var(--cm-shadow); }
  .primary-nav.is-open { display: block; }
  .primary-nav ul { display: block; }
  .primary-nav a { padding: 12px; }
  .header-actions .cm-button { display: none; }
  .cm-hero__grid { grid-template-columns: 1fr; gap: 33px; }
  .cm-platform-panel { max-width: 570px; }
  .cm-post-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .cm-single__layout { grid-template-columns: minmax(0,1fr); }
  .cm-sidebar { position: static; padding-top: 10px; }
}
@media (max-width: 620px) {
  .cm-container { width: min(100% - 28px, 1180px); }
  .site-title { font-size: 20px; }
  .cm-hero { padding: 48px 0 52px; }
  .cm-hero h1 { font-size: 40px; }
  .cm-hero__lead { font-size: 17px; }
  .cm-platform-grid { gap: 8px; }
  .cm-platform { min-height: 98px; padding: 13px; }
  .cm-page-header { padding: 34px 0 23px; }
  .cm-page-content, .cm-archive, .cm-single { padding: 32px 0 56px; }
  .entry-content { font-size: 17px; line-height: 1.72; }
  .entry-content h2 { margin-top: 1.8em; }
  .entry-content blockquote { margin: 1.6em 0; padding: 20px; font-size: 18px; }
  .cm-post-grid { grid-template-columns: 1fr; gap: 16px; }
  .site-footer__main { grid-template-columns: 1fr; gap: 22px; padding: 42px 0 25px; }
  .site-footer__bottom { display: block; }
  .site-footer__bottom span + span { display: block; margin-top: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
