/* =====================================================
   CONTROLS PAGE (prompter-controls.html)
   Laptops and tablets: tiles to choose from (all six always visible: picture, name, connection, "Coming soon"),
   the chosen control's picture and details below. Phones: a list; tap a control and it opens in place.
   "Compare with another control" puts two side by side. Without the script, all six simply show.
   Colours as on the product pages: orange heading and highlight, blue buttons and links, quiet greys.
   ===================================================== */
.ctl { background: #f5f5f7; padding: clamp(32px, 5vw, 64px) 20px clamp(48px, 6vw, 88px); font-family: 'Open Sans', sans-serif; color: #1d1d1f; }
.ctl button { font: inherit; color: inherit; }

/* page head */
.ctl-head { max-width: 860px; margin: 0 auto clamp(20px, 3vw, 30px); text-align: center; }
.ctl-head h1 {
    margin: 0 0 14px; font-family: 'Open Sans', sans-serif; font-size: clamp(1.75rem, 1.1rem + 2.2vw, 2.75rem);
    line-height: 1.15; font-weight: 700; letter-spacing: .04em; color: #d04426;
}
.ctl-head p { margin: 0 auto; max-width: 760px; font-size: clamp(1rem, .95rem + .3vw, 1.125rem); line-height: 1.7; color: #6e6e73; }

/* the hint (only with the script, on laptops and tablets) */
.ctl-hint { display: none; align-items: center; justify-content: center; gap: 8px; margin: 0 auto 14px; font-size: 13.5px; color: #6e6e73; }
.ctl-js .ctl-hint { display: flex; }
.ctl-hint span { width: 7px; height: 7px; border-radius: 50%; background: #d04426; }

/* the tiles: every control always visible */
.ctl-tiles { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; max-width: 1200px; margin: 0 auto 16px; }
.ctl-tile {
    position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 3px; padding: 10px 10px 12px;
    border: 1px solid #e3e3e8; border-radius: 14px; background: #fff; color: #1d1d1f; text-decoration: none;
    transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.ctl-tile:hover { border-color: #c9c9d1; color: #1d1d1f; text-decoration: none; transform: translateY(-2px); }
.ctl-tile.is-current { border-color: #d04426; box-shadow: 0 0 0 1px #d04426, 0 10px 22px -14px rgba(208, 68, 38, .55); transform: none; }
.ctl-tile:focus-visible { outline: 2px solid #3a74c9; outline-offset: 2px; }
.ctl-tile-img { display: block; width: 100%; aspect-ratio: 27 / 20; margin-bottom: 5px; }
.ctl-tile-img img { display: block; width: 100%; height: 100%; object-fit: contain; }
.ctl-tile-name { font-size: 13.5px; line-height: 1.25; font-weight: 700; }
.ctl-tile-sub { font-size: 12px; line-height: 1.3; color: #6e6e73; }
.ctl-tile .ctl-soon { position: absolute; top: 7px; right: 7px; padding: 1px 6px; font-size: 9.5px; }
.ctl-soon { display: inline-block; padding: 2px 9px; border-radius: 999px; background: #fdf1ec; color: #d04426; font-size: 11px; font-weight: 700; white-space: nowrap; }

/* each control */
.ctl-list { max-width: 1200px; margin: 0 auto; }
.ctl-panel { border: 1px solid #ececf0; border-radius: 20px; background: #fff; box-shadow: 0 24px 48px -32px rgba(16, 24, 40, .35); }
.ctl-panel + .ctl-panel { margin-top: 18px; }                          /* without the script: all six, one after another */
.ctl-js .ctl-panel:not(.is-current) { display: none; }                 /* laptops and tablets: only the chosen one */
.ctl-acc { display: none; }                                             /* the phone row (see the phone rules) */
.ctl-body {
    display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px clamp(20px, 3.5vw, 48px); align-items: center;
    padding: clamp(18px, 2.6vw, 32px);
}
.ctl-stage { position: relative; aspect-ratio: 27 / 20; max-height: 300px; margin: 0 auto; overflow: hidden; border-radius: 14px; background: #fff; }
.ctl-main { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; transition: opacity .2s ease; }
.ctl-main.is-fading { opacity: 0; }
.ctl-views { display: none; justify-content: center; gap: 8px; margin-top: 10px; }
.ctl-js .ctl-views { display: flex; }
.ctl-view { width: 64px; padding: 3px; border: 1px solid #e3e3e8; border-radius: 9px; background: #fff; cursor: pointer; }
.ctl-view:hover { border-color: #c9c9d1; }
.ctl-view[aria-pressed="true"] { border-color: #d04426; }
.ctl-view:focus-visible { outline: 2px solid #3a74c9; outline-offset: 2px; }
.ctl-view img { display: block; width: 100%; height: auto; aspect-ratio: 27 / 20; object-fit: contain; }
.ctl-info h2 { margin: 0 0 4px; font-family: 'Open Sans', sans-serif; font-size: clamp(1.4rem, 1.05rem + 1vw, 1.85rem); line-height: 1.2; font-weight: 700; color: #1d1d1f; }
.ctl-badge { display: inline-block; margin: 4px 0 0; padding: 3px 11px; border-radius: 999px; background: #fdf1ec; color: #d04426; font-size: 12px; font-weight: 700; }
.ctl-specs { margin: 14px 0 20px; }
.ctl-specs > div { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 14px; padding: 9px 0; border-top: 1px solid #ececf0; }
.ctl-specs > div:last-child { border-bottom: 1px solid #ececf0; }
.ctl-specs dt { font-size: 13.5px; line-height: 1.5; color: #6e6e73; }
.ctl-specs dd { margin: 0; font-size: 14.5px; line-height: 1.5; color: #1d1d1f; }
.ctl-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; }
.ctl-quote {
    display: inline-flex; align-items: center; min-height: 44px; padding: 0 22px; border-radius: 12px;
    background: #3a74c9; color: #fff; font-weight: 600; text-decoration: none;
}
.ctl-quote:hover, .ctl-quote:focus-visible { background: #2c65b9; color: #fff; text-decoration: none; }
.ctl-brochure { display: inline-flex; align-items: center; gap: 7px; color: #3a74c9; font-weight: 600; text-decoration: none; }
.ctl-brochure:hover, .ctl-brochure:focus-visible { color: #2c65b9; text-decoration: none; }
.ctl-brochure svg { width: 16px; height: 16px; }

/* compare with another control (only with the script) */
.ctl-compare { display: none; grid-column: 1 / -1; padding-top: 14px; border-top: 1px solid #ececf0; }
.ctl-js .ctl-compare { display: block; }
.ctl-compare-open { display: inline-flex; align-items: center; gap: 8px; padding: 0; border: 0; background: none; color: #3a74c9; font-size: 14.5px; font-weight: 600; cursor: pointer; }
.ctl-compare-open svg { width: 18px; height: 18px; }
.ctl-compare-open[aria-expanded="true"] { color: #1d1d1f; }
.ctl-compare-open:focus-visible { outline: 2px solid #3a74c9; outline-offset: 3px; border-radius: 4px; }
.ctl-compare-box { margin-top: 14px; }
.ctl-compare-box[hidden] { display: none; }
.ctl-compare-pick { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 14px; }
.ctl-compare-pick > span { margin-right: 2px; font-size: 13.5px; color: #6e6e73; }
.ctl-chip { padding: 7px 14px; border: 1px solid #e3e3e8; border-radius: 999px; background: #fff; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.ctl-chip:hover { border-color: #c9c9d1; }
.ctl-chip[aria-pressed="true"] { border-color: #3a74c9; background: #eef4fc; color: #2c65b9; }
.ctl-chip:focus-visible { outline: 2px solid #3a74c9; outline-offset: 2px; }
.ctl-compare-t { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 14px; }
.ctl-compare-t th, .ctl-compare-t td { padding: 9px 10px; text-align: left; vertical-align: top; border-bottom: 1px solid #ececf0; }
.ctl-compare-t thead th { font-size: 14.5px; font-weight: 700; background: #fafafb; }
.ctl-compare-t thead th:first-child, .ctl-compare-t tbody th { width: 160px; }
.ctl-compare-t tbody th { font-weight: 400; color: #6e6e73; }
.ctl-compare-t thead .ctl-soon { margin-left: 4px; font-size: 10px; }
.ctl-compare-t tr.is-highlight th, .ctl-compare-t tr.is-highlight td { background: #fffaf7; font-weight: 600; }
.ctl-compare-t tr.is-highlight th { color: #d04426; }
.ctl-compare-same { margin: 10px 0 0; font-size: 13px; line-height: 1.55; color: #6e6e73; }
.ctl-compare-same b { font-weight: 600; color: #1d1d1f; }

/* tablets: the tiles in two rows of three, bigger; the panel stacks below 760 px */
@media (max-width: 1023px) {
    .ctl-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .ctl-tile-name { font-size: 14px; }
}
@media (max-width: 760px) {
    .ctl-body { grid-template-columns: 1fr; }
    .ctl-media { width: 100%; max-width: 520px; margin: 0 auto; }
}

/* phones: a list; tap a control and it opens in place */
@media (max-width: 640px) {
    .ctl-js .ctl-tiles, .ctl-js .ctl-hint { display: none; }
    .ctl-js .ctl-panel:not(.is-current) { display: block; }
    .ctl-js .ctl-panel { border-color: #e3e3e8; border-radius: 14px; box-shadow: none; overflow: hidden; }
    .ctl-js .ctl-panel + .ctl-panel { margin-top: 8px; }
    .ctl-js .ctl-panel.is-current { border-color: #d04426; }
    .ctl-js .ctl-panel:not(.is-current) .ctl-body { display: none; }
    .ctl-js .ctl-acc {
        display: grid; grid-template-columns: 64px minmax(0, 1fr) 18px; gap: 12px; align-items: center;
        width: 100%; padding: 9px 12px 9px 9px; border: 0; background: none; text-align: left; cursor: pointer;
    }
    .ctl-acc-img { display: block; width: 64px; aspect-ratio: 27 / 20; }
    .ctl-acc-img img { display: block; width: 100%; height: 100%; object-fit: contain; }
    .ctl-acc-name { display: block; font-size: 15px; font-weight: 700; }
    .ctl-acc-sub { display: block; margin-top: 1px; font-size: 12.5px; color: #6e6e73; }
    .ctl-acc-text .ctl-soon { margin-top: 4px; font-size: 10px; }
    .ctl-acc-chev { width: 10px; height: 10px; margin-top: -4px; border-right: 2px solid #6e6e73; border-bottom: 2px solid #6e6e73; transform: rotate(45deg); transition: transform .2s ease; }
    .ctl-panel.is-current .ctl-acc-chev { margin-top: 4px; transform: rotate(-135deg); }
    .ctl-acc:focus-visible { outline: 2px solid #3a74c9; outline-offset: -2px; }
    .ctl-js .ctl-body { padding: 0 14px 16px; }
    .ctl-stage { max-height: 220px; }
    .ctl-specs > div { grid-template-columns: 112px minmax(0, 1fr); gap: 12px; }
    .ctl-compare-t { font-size: 13px; }
    .ctl-compare-t thead th:first-child, .ctl-compare-t tbody th { width: 96px; }
}
@media (prefers-reduced-motion: reduce) { .ctl-main, .ctl-tile, .ctl-acc-chev { transition: none; } }
