/* Screens */
.screen {
    position: absolute;
    inset: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;

    /* hidden by default */
    transform: translateX(100%);
    opacity: 0.01;
    pointer-events: none;
}

.screen--active {
    transform: translateX(0);
    opacity: 1;
    pointer-events: auto;
}

/* Slide animation states applied by TS */
.screen--enter-from-right {
    transform: translateX(100%);
}
.screen--enter-from-left {
    transform: translateX(-100%);
}
.screen--exit-to-left {
    transform: translateX(-100%);
}
.screen--exit-to-right {
    transform: translateX(100%);
}

.screen--animating {
    transition:
        transform 220ms ease,
        opacity 220ms ease;
}

.screenContent {
    padding: 12px;
}

/* Tile grid */
.tileGrid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;

    grid-auto-rows: 96px;
}

/*@media (min-width: 420px) {
    .tileGrid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        grid-auto-rows: 76px;
    }
}*/

.tileGrid--single {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

/* Tile base */
.tile {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
    height: 100%;
    border: 1px solid var(--border);
    background: var(--card);
    color: var(--card-foreground);
    border-radius: 0px;
    gap: 8px;

    padding: 10px;
    text-align: left;
    position: relative;

    user-select: none;
    -webkit-tap-highlight-color: transparent;

    transition:
        transform 120ms ease,
        box-shadow 120ms ease,
        background-color 120ms ease;
}

.tile:active {
    outline: none;
    transform: scale(0.97);
    box-shadow: 0 0 0 3px var(--ring);
}

/* Sizes */
.tile--small {
    grid-column: span 1;
    grid-row: span 1;
}
.tile--medium {
    grid-column: span 2;
    grid-row: span 1;
}
.tile--wide {
    grid-column: span 2;
    grid-row: span 1;
}

/* Accents */
.tile--primary {
    background: var(--primary);
    color: var(--primary-foreground);
    border-color: var(--primary);
}

.tile--accent {
    background: var(--accent);
    color: var(--accent-foreground);
    border-color: var(--accent);
}

.tile--back {
    background: var(--muted);
    color: var(--muted-foreground);
    border-color: var(--border);
}

.tile__title {
    position: static;
    left: 12px;
    bottom: 10px;
    font-size: 18px;
    font-weight: 600;
    letter-spacing: 0.2px;
}

.tile__subtitle {
    font-size: 13px;
    opacity: 0.75;
    transition: opacity 180ms ease;
}

.tile__icon {
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 20px;
    line-height: 1;
    opacity: 0.85;
}
