/* The program pages (/padel, /tenis, /polideportivo, /club-de-socios, /escuela-deportiva,
   /simulador-de-golf): the home's sheet, plus the pictures of the program drawn in HTML. A
   window is an admin screen, a phone is the customer's side, a ticket is what they get.
   Flat like the rest of the site: solid colours and thin borders. */

/* ==================== Hero ==================== */
.lp-price {
    margin-top: 1rem;
    font-size: 1.0625rem;
    color: var(--text-muted);
}

.lp-price strong {
    font-family: var(--font-display);
    font-size: 1.5rem;
    color: var(--heading);
    margin-inline-end: 0.25rem;
}

/* ==================== An admin window ==================== */
.lp-window {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    overflow: hidden;
    font-size: 0.75rem;
    color: var(--text);
}

.lp-window-bar {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 0.625rem 0.875rem;
    background: var(--bg-warm);
    border-bottom: 1px solid var(--border-light);
}

.lp-window-bar em {
    display: flex;
    font-style: normal;
}

.lp-window-bar i {
    display: inline-block;
    width: 0.5rem;
    height: 0.5rem;
    margin-inline-end: 0.3rem;
    border-radius: 50%;
    background: var(--border);
}

.lp-window-bar span {
    flex: 1;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    background: white;
    border: 1px solid var(--border-light);
    font-family: var(--font-mono);
    font-size: 0.6875rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lp-window-bar span b {
    font-weight: 600;
    color: var(--heading);
}

.lp-window-body {
    padding: 1.125rem 1.25rem 1.25rem;
}

.lp-window-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.lp-window-head strong {
    font-family: var(--font-display);
    font-size: 1.0625rem;
    color: var(--heading);
}

.lp-chip {
    padding: 0.15rem 0.6rem;
    border-radius: 999px;
    background: var(--primary-subtle);
    color: var(--primary-dark);
    font-weight: 600;
}

.lp-legend {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--text-muted);
}

.lp-legend i {
    width: 0.625rem;
    height: 0.625rem;
    border-radius: 3px;
    margin-inline-start: 0.5rem;
}

.lp-legend .k-book { background: var(--primary); }
.lp-legend .k-class { background: #9bb81c; }
.lp-legend .k-event { background: #7c3aed; }

/* ==================== The timetable: one column per court, bay or room ==================== */
.lp-timetable {
    --cols: 4;
    display: grid;
    grid-template-columns: 2.75rem repeat(var(--cols), minmax(0, 1fr));
    grid-template-rows: auto repeat(10, 1.9rem);
    gap: 3px 6px;
}

.lp-h {
    grid-column: 1;
    color: var(--text-light);
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.lp-c {
    grid-row: 1;
    font-weight: 600;
    color: var(--text-muted);
    padding-bottom: 0.5rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lp-b {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    padding: 0.4rem 0.5rem;
    border-radius: 6px;
    overflow: hidden;
    line-height: 1.25;
}

.lp-b b,
.lp-b span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lp-b b { font-weight: 600; }
.lp-b span { opacity: 0.8; }

.lp-b.k-book {
    background: var(--primary-subtle);
    border-inline-start: 3px solid var(--primary);
    color: var(--heading);
}

.lp-b.k-due { border-inline-start-color: var(--warn); }
.lp-b.k-due span { color: #92400e; opacity: 1; }

.lp-b.k-class {
    background: #f4fbd0;
    border-inline-start: 3px solid #9bb81c;
    color: #1f2a05;
}

.lp-b.k-event {
    background: #f1ecfe;
    border-inline-start: 3px solid #7c3aed;
    color: #2e1065;
}

/* ==================== A list screen ==================== */
.lp-table {
    display: flex;
    flex-direction: column;
}

.lp-row {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.2fr) minmax(0, 0.9fr) minmax(0, 0.6fr);
    gap: 0.75rem;
    align-items: center;
    padding: 0.6rem 0.25rem;
    border-top: 1px solid var(--border-light);
}

.lp-row > * {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lp-row > :first-child { font-weight: 600; color: var(--heading); }
.lp-row > :last-child { text-align: end; font-variant-numeric: tabular-nums; font-weight: 600; }

.lp-row-head {
    border-top: none;
    padding-top: 0;
    font-size: 0.625rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-light);
}

.lp-row-head > :first-child,
.lp-row-head > :last-child { font-weight: 600; color: var(--text-light); }

.lp-row-hit { background: var(--primary-subtle); border-radius: 6px; }

.lp-ok,
.lp-due,
.lp-off {
    justify-self: start;
    padding: 0.1rem 0.5rem;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.6875rem;
}

.lp-ok { background: var(--success-light); color: var(--success-dark); }
.lp-due { background: #fef3c7; color: #92400e; }
.lp-off { background: var(--bg-alt); color: var(--text-muted); }

.lp-sum {
    display: flex;
    justify-content: space-between;
    margin-top: 0.75rem;
    padding: 0.75rem 0.25rem 0;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
}

.lp-sum b {
    font-variant-numeric: tabular-nums;
    color: var(--heading);
}

/* ==================== The customer's side ==================== */
/* A phone and what it got, side by side on a plain panel. */
.lp-stage {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: 1.5rem;
    padding: 2.5rem 2rem;
    background: var(--bg-alt);
    border-radius: var(--radius-xl);
}

.lp-phone {
    flex: 0 0 auto;
    width: 15.5rem;
    padding: 1rem 0.875rem 0.875rem;
    border-radius: 2rem;
    background: white;
    border: 6px solid #0b0d12;
    font-size: 0.75rem;
    color: var(--text);
}

.lp-phone-top {
    display: flex;
    flex-direction: column;
    margin-bottom: 0.75rem;
}

.lp-phone-top span {
    color: var(--text-muted);
    font-size: 0.6875rem;
}

.lp-phone-top strong {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.0625rem;
    color: var(--heading);
}

.lp-days {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.3rem;
    margin-bottom: 0.625rem;
}

.lp-days span {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.3rem 0;
    border-radius: 0.6rem;
    background: var(--bg-alt);
    font-weight: 600;
    font-size: 0.8125rem;
}

.lp-days b {
    font-weight: 500;
    font-size: 0.625rem;
    color: var(--text-muted);
}

.lp-days .on { background: var(--primary); color: white; }
.lp-days .on b { color: rgba(255, 255, 255, 0.8); }

.lp-res {
    padding: 0.45rem 0;
    border-top: 1px solid var(--border-light);
}

.lp-res strong {
    display: block;
    font-weight: 600;
    margin-bottom: 0.3rem;
}

.lp-res em {
    font-style: normal;
    font-weight: 400;
    color: var(--text-muted);
}

.lp-slots {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.3rem;
}

.lp-slots span {
    text-align: center;
    padding: 0.28rem 0;
    border-radius: 0.45rem;
    border: 1px solid var(--border);
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.lp-slots .off {
    color: var(--text-light);
    background: var(--bg-alt);
    border-color: transparent;
    text-decoration: line-through;
}

.lp-slots .pick {
    background: var(--primary-subtle);
    border-color: var(--primary);
    color: var(--primary-dark);
}

/* A list of things to sign up to: a class, an event, a camp. */
.lp-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 0;
    border-top: 1px solid var(--border-light);
}

.lp-item div {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.lp-item b {
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lp-item span { color: var(--text-muted); }

.lp-item em {
    flex: 0 0 auto;
    font-style: normal;
    font-weight: 600;
    font-size: 0.6875rem;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    background: var(--primary-subtle);
    color: var(--primary-dark);
}

.lp-item em.full { background: var(--bg-alt); color: var(--text-muted); }

/* The register: who came, ticked from the phone. */
.lp-check {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 0;
    border-top: 1px solid var(--border-light);
}

.lp-check i {
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    width: 1.125rem;
    height: 1.125rem;
    border-radius: 0.3rem;
    border: 1.5px solid var(--border);
    font-style: normal;
    font-size: 0.6875rem;
    color: white;
}

.lp-check i.on { background: var(--primary); border-color: var(--primary); }
.lp-check span { flex: 1; }
.lp-check em { font-style: normal; color: var(--text-light); }

.lp-toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin: 0.5rem 0;
    padding: 0.2rem;
    border-radius: 0.6rem;
    background: var(--bg-alt);
    text-align: center;
    font-weight: 600;
    color: var(--text-muted);
}

.lp-toggle span { padding: 0.28rem 0; border-radius: 0.45rem; }
.lp-toggle .on { background: white; color: var(--text); border: 1px solid var(--border-light); }

.lp-pay {
    margin-top: 0.5rem;
    padding: 0.6rem 0;
    border-radius: 999px;
    background: var(--primary);
    color: white;
    text-align: center;
    font-weight: 600;
    font-size: 0.875rem;
}

.lp-pay small {
    font-weight: 400;
    opacity: 0.75;
    margin-inline-start: 0.25rem;
}

/* What the customer got: the booking, the place, the pack. */
.lp-ticket {
    flex: 0 1 17rem;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    margin-bottom: 1.5rem;
    padding: 1.125rem 1.25rem;
    border-radius: var(--radius-xl);
    background: white;
    border: 1px solid var(--border);
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.lp-ticket strong {
    font-family: var(--font-display);
    font-size: 1.0625rem;
    color: var(--heading);
}

.lp-ticket-ok {
    align-self: flex-start;
    margin-bottom: 0.35rem;
    padding: 0.15rem 0.6rem;
    border-radius: 999px;
    background: var(--success-light);
    color: var(--success-dark);
    font-weight: 600;
    font-size: 0.75rem;
}

.lp-ticket-players {
    display: flex;
    align-items: center;
    margin-top: 0.75rem;
}

.lp-ticket-players i {
    display: grid;
    place-items: center;
    width: 1.875rem;
    height: 1.875rem;
    margin-inline-end: -0.4rem;
    border-radius: 50%;
    border: 2px solid white;
    background: var(--bg-alt);
    color: var(--text-muted);
    font-style: normal;
    font-size: 0.625rem;
    font-weight: 700;
}

.lp-ticket-players i.paid { background: var(--primary); color: white; }

.lp-ticket-players em {
    font-style: normal;
    margin-inline-start: 1rem;
}

.lp-ticket-foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.875rem;
    padding-top: 0.75rem;
    border-top: 1px dashed var(--border);
}

.lp-ticket-foot b {
    font-family: var(--font-display);
    font-size: 1.125rem;
    color: var(--heading);
}

/* a door PIN reads digit by digit */
.lp-ticket-foot b.pin {
    font-family: var(--font-mono);
    letter-spacing: 0.15em;
}

/* A balance used up step by step: hours of a pack, classes of a pack. */
.lp-meter {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 3px;
    margin-top: 0.75rem;
}

.lp-meter i {
    height: 0.5rem;
    border-radius: 2px;
    background: var(--primary);
}

.lp-meter i.used { background: var(--border-light); }

/* In a reversed block the picture goes first on a wide screen and after the text on a
   narrow one, the way site.css orders a .showcase-image. */
.showcase-block-reverse > .lp-window,
.showcase-block-reverse > .lp-stage { order: 1; }

/* ==================== Narrow screens ==================== */
@media (max-width: 1024px) {
    .lp-window { max-width: 40rem; }
    .showcase-block-reverse > .lp-window,
    .showcase-block-reverse > .lp-stage { order: 2; }
}

@media (max-width: 768px) {
    .lp-window-body { padding: 0.875rem; }
    .lp-window { font-size: 0.6875rem; }
    .lp-timetable { grid-template-columns: 2.25rem repeat(var(--cols), minmax(0, 1fr)); gap: 3px 4px; }
    .lp-b span { display: none; }
    .lp-row { grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.9fr) minmax(0, 0.6fr); }
    .lp-row > :nth-child(2) { display: none; }
    .lp-stage { flex-direction: column; align-items: center; padding: 1.75rem 1rem; }
    .lp-ticket { flex: 0 0 auto; width: 100%; max-width: 17rem; margin-bottom: 0; }
}
