/* Touch-optimized overrides for iPad (~1024px wide). */

:root {
    --touch-target-min: 56px;
}

body {
    font-size: 1.125rem;
}

.touch-input,
.touch-select {
    min-height: var(--touch-target-min);
    font-size: 1.25rem;
    padding: 0.75rem 1rem;
    width: 100%;
}

.touch-select {
    height: auto;
    background-image: none;
}

.touch-button,
.touch-button-large {
    min-height: var(--touch-target-min);
    font-size: 1.125rem;
    padding-left: 2rem;
    padding-right: 2rem;
}

.touch-button-large {
    min-height: 72px;
    font-size: 1.375rem;
    font-weight: 500;
}

/* Custom touch-friendly checkbox: native input enlarged, sat beside its label
   via flex. Avoids Vanilla's .p-checkbox absolute-positioning trickery, which
   doesn't combine well with the flex layout we need for a tap target. */
.touch-checkbox {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.125rem;
    min-height: var(--touch-target-min);
    cursor: pointer;
    padding: 0;
}

.touch-checkbox__input {
    width: 1.5rem;
    height: 1.5rem;
    margin: 0;
    flex-shrink: 0;
    cursor: pointer;
}

.touch-checkbox__label {
    line-height: 1.4;
}

/* Header alignment: keep all nav items vertically centred and use the same
   visual treatment regardless of whether the child is <a>, <button>, or <span>. */
.p-navigation__items {
    display: flex;
    align-items: center;
}

.p-navigation__item {
    display: flex;
    align-items: stretch;
}

.p-navigation__item > .p-navigation__link {
    display: flex;
    align-items: center;
}

.link-button {
    background: none;
    border: none;
    cursor: pointer;
    font: inherit;
    color: inherit;
    text-decoration: none;
}

.link-button:hover,
.link-button:focus {
    text-decoration: underline;
    color: inherit;
}

#last-payment-card {
    margin-top: 1.5rem;
}

#last-payment-card .p-status-label {
    margin-left: 0.5rem;
}

#today-list .p-list__item {
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    font-size: 1.0625rem;
}

#today-list .p-list__item:last-child {
    border-bottom: none;
}

.p-modal[hidden] {
    display: none !important;
}

.payment-warning {
    color: #c7162b;
    font-weight: 500;
}

.payment-ok {
    color: #0e8420;
}

/* Dashboard day cards. */
.day-card {
    display: block;
    padding: 1.25rem 1.5rem;
    margin-bottom: 0.75rem;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    text-decoration: none;
    color: inherit;
    transition: background 0.15s ease;
}

.day-card:hover,
.day-card:focus {
    background: #f7f7f7;
    text-decoration: none;
    color: inherit;
}

.day-card__date {
    font-size: 1.25rem;
    font-weight: 500;
}

.day-card__count {
    font-size: 1rem;
    color: #666;
    margin-top: 0.25rem;
}

.day-card__count strong {
    color: #111;
    font-size: 1.125rem;
}

.day-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.day-table th,
.day-table td {
    text-align: left;
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.day-table th {
    font-weight: 500;
    color: #666;
    font-size: 0.95rem;
}

.copy-status {
    margin-left: 0.75rem;
    color: #0e8420;
    font-weight: 500;
}

.profile-field {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.profile-field__label {
    color: #666;
}
