/**
 * Product: Banner Exchange 468x60
 * Developer: DIMSTART
 * Website: https://dimstart.ru/
 * Version: 2.1.1
 * License: Commercial
 */

:root {
      --bg: #f4f2ec;
      --panel: #fffdfa;
      --ink: #242424;
      --muted: #6f6a60;
      --line: #d8d2c4;
      --accent: #0b6f6a;
      --accent-strong: #084f4c;
      --warn: #9f5a00;
      --ok: #2f7d32;
      --shadow: 0 10px 24px rgba(42, 37, 27, 0.08);
    }

    * {
      box-sizing: border-box;
    }

    body {
      margin: 0;
      min-height: 100vh;
      background: var(--bg);
      color: var(--ink);
      font-family: Arial, Helvetica, sans-serif;
      font-size: 15px;
      line-height: 1.45;
    }

    a {
      color: inherit;
    }

    .site-header {
      position: sticky;
      top: 0;
      z-index: 10;
      border-bottom: 1px solid var(--line);
      background: rgba(255, 253, 250, 0.96);
      backdrop-filter: blur(10px);
    }

    .header-inner,
    .footer-inner,
    main {
      width: min(980px, calc(100% - 32px));
      margin: 0 auto;
    }

    .header-inner {
      display: flex;
      align-items: center;
      justify-content: space-between;
      min-height: 64px;
      gap: 20px;
    }

    .brand {
      display: flex;
      align-items: center;
      gap: 10px;
      min-width: 220px;
      font-weight: 700;
      letter-spacing: 0;
    }

    .brand-mark {
      display: grid;
      width: 34px;
      height: 34px;
      place-items: center;
      border: 2px solid var(--ink);
      background: #ffd166;
      font-size: 12px;
      line-height: 1;
    }

    .top-nav {
      display: flex;
      flex-wrap: wrap;
      justify-content: flex-end;
      gap: 4px;
    }

    .top-nav a {
      min-height: 36px;
      padding: 9px 12px;
      border-radius: 6px;
      color: var(--muted);
      text-decoration: none;
      white-space: nowrap;
    }

    .top-nav a[aria-current="page"],
    .top-nav a:hover {
      background: #ebe5d8;
      color: var(--ink);
    }

    main {
      padding: 28px 0 40px;
    }

    .intro {
      display: flex;
      align-items: flex-end;
      justify-content: space-between;
      gap: 20px;
      margin-bottom: 16px;
    }

    h1 {
      margin: 0;
      font-size: 28px;
      line-height: 1.15;
      letter-spacing: 0;
    }

    .status-line {
      color: var(--muted);
      font-weight: 700;
      white-space: nowrap;
    }

    .status-line strong {
      color: var(--accent-strong);
    }

    .countdown-pill {
      display: none;
      margin-left: 10px;
      padding: 5px 8px;
      border-radius: 6px;
      background: #ffd166;
      color: #242424;
      font-size: 13px;
      font-weight: 700;
    }

    .countdown-pill.active {
      display: inline-block;
    }

    .add-panel {
      display: grid;
      grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr) auto;
      gap: 10px;
      padding: 14px;
      border: 1px solid var(--line);
      border-radius: 8px;
      background: var(--panel);
      box-shadow: var(--shadow);
    }

    label {
      display: grid;
      gap: 6px;
      color: var(--muted);
      font-size: 12px;
      font-weight: 700;
      text-transform: uppercase;
    }

    input {
      width: 100%;
      min-height: 42px;
      border: 1px solid #bbb3a3;
      border-radius: 6px;
      padding: 0 12px;
      background: #fff;
      color: var(--ink);
      font: inherit;
    }

    button {
      min-height: 42px;
      border: 0;
      border-radius: 6px;
      padding: 0 16px;
      background: var(--accent);
      color: #fff;
      font: inherit;
      font-weight: 700;
      cursor: pointer;
    }

    button:hover:not(:disabled) {
      background: var(--accent-strong);
    }

    button:disabled {
      background: #b9b2a4;
      color: #f7f4ee;
      cursor: not-allowed;
    }

    .notice {
      min-height: 24px;
      margin: 10px 0 18px;
      color: var(--muted);
    }

    .notice strong {
      color: var(--warn);
    }

    .page-content {
      min-height: 420px;
      padding: 22px 0 10px;
      border-top: 1px solid var(--line);
    }

    .page-content p {
      max-width: 680px;
      margin: 0 0 12px;
      color: var(--muted);
    }

    .top-horizontal-ad {
      display: flex;
      justify-content: center;
      margin: 0 0 18px;
    }

    .horizontal-ad-creative {
      display: grid;
      width: 468px;
      height: 60px;
      place-content: center;
      border: 1px dashed #8d8372;
      border-radius: 6px;
      background: linear-gradient(135deg, #fffdfa 0%, #f1ede4 100%);
      color: var(--muted);
      text-align: center;
      line-height: 1.15;
      box-shadow: 0 4px 14px rgba(42, 37, 27, 0.04);
    }

    .horizontal-ad-creative strong {
      color: var(--ink);
      font-size: 14px;
    }

    .horizontal-ad-creative span {
      margin-top: 2px;
      font-size: 12px;
      font-weight: 700;
    }

    .content-grid {
      display: grid;
      grid-template-columns: minmax(0, 1fr) 200px;
      align-items: start;
      gap: 18px;
    }

    .banner-list {
      display: grid;
      gap: 12px;
    }

    .banner-row {
      display: grid;
      grid-template-columns: 468px minmax(0, 1fr);
      align-items: center;
      gap: 14px;
      min-height: 82px;
      padding: 10px;
      border: 1px solid var(--line);
      border-radius: 8px;
      background: var(--panel);
      box-shadow: 0 4px 14px rgba(42, 37, 27, 0.04);
    }

    .inline-ad-row {
      background: #f8f5ee;
    }

    .inline-ad-row .horizontal-ad-creative {
      justify-self: center;
      box-shadow: none;
    }

    .inline-ad-row .banner-title {
      margin-bottom: 7px;
    }

    .inline-ad-row .view-state {
      background: #eee7d8;
      color: var(--accent-strong);
      font-weight: 700;
    }

    .banner-button {
      width: 468px;
      height: 60px;
      padding: 0;
      border: 1px solid #2c2c2c;
      border-radius: 0;
      background: #fff;
      overflow: hidden;
      box-shadow: none;
    }

    .banner-button img {
      display: block;
      width: 468px;
      height: 60px;
      object-fit: cover;
    }

    .banner-meta {
      display: grid;
      align-content: center;
      min-width: 0;
      min-height: 60px;
      padding: 4px 6px;
      color: var(--muted);
    }

    .banner-title {
      margin-bottom: 7px;
      color: var(--ink);
      font-size: 15px;
      font-weight: 700;
      line-height: 1.3;
      overflow-wrap: anywhere;
    }

    .view-state {
      width: fit-content;
      max-width: 100%;
      padding: 5px 8px;
      border-radius: 5px;
      background: #f0ece3;
      color: var(--muted);
      font-size: 12px;
      line-height: 1.3;
    }

    .viewed .view-state {
      background: #e8f3e8;
      color: var(--ok);
      font-weight: 700;
    }

    .ad-rail {
      position: sticky;
      top: 82px;
      display: grid;
      gap: 12px;
    }

    .ad-slot {
      display: grid;
      width: 200px;
      height: 300px;
      place-items: center;
      border: 1px dashed #8d8372;
      border-radius: 8px;
      background: #fffdfa;
      color: var(--muted);
      text-align: center;
      font-weight: 700;
      box-shadow: var(--shadow);
    }

    .ad-slot span {
      display: block;
      color: var(--ink);
      font-size: 20px;
    }

    .site-footer {
      border-top: 1px solid var(--line);
      background: #242424;
      color: #f6f1e7;
    }

    .footer-inner {
      display: flex;
      align-items: center;
      justify-content: space-between;
      min-height: 72px;
      gap: 18px;
    }

    .footer-links {
      display: flex;
      flex-wrap: wrap;
      gap: 14px;
    }

    .footer-links a {
      color: #f6f1e7;
      text-decoration: none;
    }

    .footer-note {
      color: #c8c0ae;
    }

    .footer-product {
      display: grid;
      gap: 3px;
    }

    .dimstart-credit {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 5px;
      margin-top: 4px;
      color: #c8c0ae;
      font-size: 12px;
      line-height: 1.35;
    }

    .dimstart-credit a {
      color: #ffd166;
      font-weight: 700;
      text-decoration: none;
    }

    .dimstart-credit a:hover {
      text-decoration: underline;
    }

    .dimstart-copyright::before {
      content: "·";
      margin-right: 5px;
      color: #837c70;
    }

    @media (max-width: 760px) {
      .header-inner,
      .footer-inner,
      .intro,
      .add-panel,
      .content-grid,
      .banner-row {
        display: grid;
      }

      .header-inner {
        justify-content: stretch;
        padding: 12px 0;
      }

      .footer-inner {
        align-items: start;
        padding: 18px 0;
      }

      .top-nav {
        justify-content: start;
      }

      .intro {
        align-items: start;
      }

      .status-line {
        white-space: normal;
      }

      .add-panel {
        grid-template-columns: 1fr;
      }

      .content-grid {
        grid-template-columns: 1fr;
      }

      .ad-rail {
        position: static;
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
      }

      .ad-slot {
        width: 100%;
        height: auto;
        min-height: 180px;
      }

      .banner-row {
        grid-template-columns: 1fr;
      }

      .banner-button,
      .banner-button img {
        width: min(468px, 100%);
        height: auto;
        aspect-ratio: 468 / 60;
      }

      .horizontal-ad-creative {
        width: min(468px, 100%);
        height: auto;
        min-height: 60px;
        aspect-ratio: 468 / 60;
      }
    }

    @media (max-width: 520px) {
      .header-inner,
      .footer-inner,
      main {
        width: min(100% - 20px, 980px);
      }

      main {
        padding-top: 20px;
      }

      h1 {
        font-size: 24px;
      }

      .brand {
        min-width: 0;
      }

      .top-nav a {
        padding: 8px 9px;
      }

      .countdown-pill {
        display: none;
        width: fit-content;
        margin: 6px 0 0;
      }

      .countdown-pill.active {
        display: block;
      }

      .banner-title {
        overflow: visible;
        text-overflow: clip;
        white-space: normal;
      }

      .ad-slot {
        min-height: 120px;
      }
    }
  

/* MySQL edition additions */
.brand-link {
  color: inherit;
  text-decoration: none;
}

.hp-field {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

.loading-card,
.empty-state,
.error-card {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  color: var(--muted);
  box-shadow: var(--shadow);
}

.error-card {
  border-color: #d99a86;
  background: #fff0eb;
  color: #8c2f15;
}

.banner-stats {
  margin-top: 7px;
  color: #8a8377;
  font-size: 11px;
}

.ad-image-link {
  display: block;
  overflow: hidden;
  padding: 0;
  border-style: solid;
}

.horizontal-ad-creative.ad-image-link,
.ad-image-link.horizontal-ad-creative {
  place-content: stretch;
}

.horizontal-ad-creative img,
.sidebar-ad-creative img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sidebar-ad-creative {
  display: grid;
  width: 200px;
  height: 300px;
  place-content: center;
  color: var(--muted);
  text-align: center;
  text-decoration: none;
}

.sidebar-ad-creative strong,
.sidebar-ad-creative span {
  display: block;
}

.sidebar-ad-creative strong {
  color: var(--ink);
  font-size: 14px;
}

.page-lead {
  max-width: 760px;
  margin: 0 0 18px;
  color: var(--muted);
}

.prose {
  max-width: 760px;
}

.prose h2 {
  margin: 26px 0 8px;
  font-size: 21px;
}

.my-banner-list {
  display: grid;
  gap: 12px;
}

.my-banner-card {
  display: grid;
  grid-template-columns: 468px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.my-banner-card img {
  display: block;
  width: 468px;
  height: 60px;
  object-fit: cover;
  border: 1px solid #2c2c2c;
}

.small-muted {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

@media (max-width: 760px) {
  .my-banner-card {
    grid-template-columns: 1fr;
  }

  .my-banner-card img,
  .sidebar-ad-creative {
    width: 100%;
    height: auto;
  }

  .my-banner-card img {
    aspect-ratio: 468 / 60;
  }

  .sidebar-ad-creative {
    min-height: 180px;
  }
}


.exchange-submit h2 {
  margin: 0 0 10px;
  font-size: 18px;
}

.format-hint {
  margin: 10px 0 18px;
  color: var(--muted);
  font-size: 13px;
}

/* Advertising network and direct-sale slot modes: version 2.1.0 */
.ad-embed-code{
  display:grid;
  place-items:center;
  overflow:hidden;
  padding:0;
  border:0;
  background:transparent;
  box-shadow:none;
}
.ad-embed-code > *{
  max-width:100%;
}
.ad-placeholder-link{
  color:inherit;
  text-decoration:none;
}
.ad-placeholder-link:hover{
  border-color:var(--accent);
  background:#fffdfa;
}
@media(max-width:760px){
  .ad-embed-code{
    max-width:100%;
  }
}
