/* -----------------------------------------------------------------------------
   FILE: healthloggerpersonal.css
   DESCRIPTION: Styles for HealthLoggerPersonal plugin (9 events + level selector)
----------------------------------------------------------------------------- */

#healthloggerpersonal-app {
    max-width: 480px;
    margin: 32px auto;
    background: #222;
    color: #fff;
    border-radius: 1.5rem;
    box-shadow: 0 2px 24px rgba(0,0,0,0.18);
    padding: 26px 14px 20px 14px;
    font-family: 'Segoe UI', Arial, sans-serif;
}

.hp-app-title {
    text-align: center;
    margin-bottom: 23px;
    font-size: 1.7em;
    color: #fff !important;
}

.hp-menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 22px;
}

.hp-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #393e46;
    border-radius: 1rem;
    padding: 14px 10px 8px 10px;
    width: 120px;
    cursor: pointer;
    transition: background 0.2s, box-shadow 0.2s;
    font-size: 1.05em;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    min-height: 153px;
    position: relative;
}

.hp-item.active,
.hp-item:hover {
    background: #00adb5;
    color: #111;
    box-shadow: 0 4px 16px rgba(0,173,181,0.18);
}

.hp-icon {
    width: 42px;
    height: 42px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hp-label {
    margin-bottom: 7px;
    font-size: 1.07em;
    font-weight: 500;
    text-align: center;
}

.hp-prediction {
    margin-top: auto;
    font-size: 0.98em;
    color: #00adb5;
    text-align: center;
    min-height: 28px;
    width: 100%;
    font-weight: 600;
    /* No flashing animation to avoid seizures */
}

.hp-prediction.hp-alert {
    color: #fff !important;
    background: #e53935;      /* Red background for “Expected soon (average)” */
    border-radius: 0.6em;
    font-weight: 700;
    /* No animation or flashing */
    box-shadow: 0 0 8px 3px #e5393580;
}

.hp-buttons {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

#hp-tap-btn {
    font-size: 1.18em;
    padding: 16px 29px;
    border-radius: 1.2em;
    border: none;
    background: #00adb5;
    color: #111;
    font-weight: 600;
    box-shadow: 0 2px 10px rgba(0,173,181,0.07);
    cursor: pointer;
    margin-bottom: 10px;
    transition: background 0.2s;
}

#hp-tap-btn:disabled {
    background: #444;
    color: #aaa;
    cursor: not-allowed;
}

#hp-level-select {
    font-size: 1em;
    padding: 8px 10px;
    border-radius: 0.6em;
    border: none;
    background: #393e46;
    color: #fff;
    cursor: pointer;
    display: none;
    margin-bottom: 10px;
}

#hp-advanced-btn {
    font-size: 1em;
    padding: 10px 16px;
    border-radius: 0.9em;
    border: none;
    background: #d32f2f; /* Red background for Advanced Settings */
    color: #fff;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

#hp-advanced-btn:hover {
    background: #b71c1c;
}

#hp-log-buttons > button {
    font-size: 1em;
    padding: 12px 16px;
    border-radius: 0.9em;
    border: none;
    background: #393e46;
    color: #fff;
    font-weight: 500;
    cursor: pointer;
    margin-top: 5px;
    margin-right: 6px;
    transition: background 0.18s;
}

#hp-log-buttons > button:hover {
    background: #00adb5;
    color: #111;
}

#hp-status {
    text-align: center;
    margin-bottom: 12px;
    font-size: 1.06em;
    min-height: 24px;
}

#hp-log-table {
    margin-top: 15px;
    max-height: 210px;
    overflow-y: auto;
}

#hp-log-table table {
    width: 100%;
    border-collapse: collapse;
    background: #393e46;
    border-radius: 0.9em;
    overflow: hidden;
}

#hp-log-table th,
#hp-log-table td {
    padding: 7px 9px;
    text-align: center;
}

#hp-log-table th {
    background: #00adb5;
    color: #111;
}

#hp-log-table tr:nth-child(even) td {
    background: #333;
}

/* QR modal styling */
#hp-qr-modal,
#hp-qrscan-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(30,30,30,0.84);
    align-items: center;
    justify-content: center;
}

#hp-qr-modal.active,
#hp-qrscan-modal.active {
    display: flex;
}

.hp-qr-modal-content {
    background: #262b35;
    margin: auto;
    padding: 26px 22px 14px 22px;
    border-radius: 1.2em;
    box-shadow: 0 8px 36px #000a;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

#hp-qr-close,
#hp-qrscan-close {
    position: absolute;
    top: 8px;
    right: 20px;
    font-size: 2.1em;
    color: #fff;
    cursor: pointer;
}

#hp-qr-box {
    margin-bottom: 13px;
}

#hp-qr-info,
#hp-qrscan-info {
    color: #fff;
    text-align: center;
    font-size: 1em;
    margin-bottom: 6px;
}

#hp-qr-video {
    width: 280px;
    height: 220px;
    border-radius: 0.7em;
    margin-bottom: 13px;
    background: #000;
}

/* -----------------------------------------------------------------------------
   INFO BOX FOR HealthLoggerPersonal Description
----------------------------------------------------------------------------- */

.hl-desc-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #262b35;
    color: #fff;
    border-radius: 1rem;
    box-shadow: 0 2px 24px rgba(0,0,0,0.18);
    padding: 18px 20px;
    margin-bottom: 24px;
    font-family: 'Segoe UI', Arial, sans-serif;
    text-align: center;
}

.hl-desc-icon {
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    margin-bottom: 10px;
}

.hl-desc-icon svg {
    width: 100%;
    height: 100%;
    display: block;
}

.hl-desc-text {
    font-size: 1em;
    line-height: 1.5;
    max-width: 600px;
    margin-bottom: 12px;
}

.hl-disclaimer {
    font-size: 0.9em;
    color: #bbb;
    margin-top: 8px;
    max-width: 600px;
}
