/* PolyQuest Control stylesheet: circa-2015 CSS 3 flexbox only, smartphone-first, Tizen/older mobile safe. */
* {
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    min-height: 100%;
    background: #14201b;
    color: #f4f7f5;
    font-family: "Trebuchet MS", "Segoe UI", Arial, Helvetica, sans-serif;
    -webkit-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.shell {
    max-width: 560px;
    margin: 0 auto;
    padding: 8px 10px 12px 10px;
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    min-height: 100vh;
}

.topBar {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: space-between;
    justify-content: space-between;
    margin-bottom: 7px;
}

.backLink {
    display: inline-block;
    padding: 6px 11px;
    border-radius: 8px;
    background: #22352c;
    border: 1px solid #486b59;
    color: #e6f5ec;
    text-decoration: none;
    font-size: 13px;
    font-weight: bold;
}

.commsBadge {
    font-family: monospace;
    font-size: 12px;
    padding: 5px 9px;
    border-radius: 7px;
    background: #2b2416;
    border: 1px solid #8a6d2b;
    color: #fde68a;
}
.commsBadge.is-ok { background: #193829; border-color: #3d8e5f; color: #bbf7d0; }

.panel {
    margin-bottom: 7px;
    padding: 9px 10px;
    border-radius: 11px;
    background: #1b2a24;
    border: 1px solid #354f44;
}

.heroHeader {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    margin-bottom: 7px;
}

.heroSwatch {
    width: 36px;
    height: 36px;
    line-height: 36px;
    text-align: center;
    border-radius: 9px;
    background: #ef4444;
    color: #ffffff;
    font-weight: bold;
    font-size: 14px;
    margin-right: 9px;
    -webkit-flex-shrink: 0;
    flex-shrink: 0;
}

.heroMeta { -webkit-flex: 1; flex: 1; min-width: 0; }
.heroTitle { font-size: 15px; font-weight: bold; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.heroSub { font-size: 11px; color: #a7c4b8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.relicBadge {
    padding: 4px 8px;
    border-radius: 7px;
    background: #2d2614;
    border: 1px solid #eab308;
    color: #fde047;
    font-family: monospace;
    font-size: 12px;
    font-weight: bold;
    margin-left: 6px;
}

.nameRow {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    margin-bottom: 7px;
}
.nameLabel { font-size: 12px; font-weight: bold; color: #a7c4b8; margin-right: 7px; }
.nameInput {
    -webkit-flex: 1;
    flex: 1;
    min-width: 0;
    padding: 6px 8px;
    border-radius: 7px;
    border: 1px solid #486b59;
    background: #111b17;
    color: #ffffff;
    font-family: inherit;
    font-size: 14px;
    -webkit-user-select: text;
    user-select: text;
}
.storageNotice { margin-left: 6px; font-size: 10px; color: #fde68a; }

.classRow {
    display: -webkit-flex;
    display: flex;
    margin: 0 -3px 5px -3px;
}
.clsBtn {
    -webkit-flex: 1;
    flex: 1;
    margin: 0 3px;
    padding: 7px 4px;
    border-radius: 8px;
    border: 1px solid #456256;
    background: #15221d;
    color: #cde0d7;
    font-family: inherit;
    font-size: 12px;
    font-weight: bold;
    cursor: pointer;
}
.clsBtn.is-active { background: #2a854a; border-color: #86efac; color: #ffffff; }
.classDesc { font-size: 11px; color: #b7d2c6; line-height: 1.3; }

.lobbyPanel { background: #1c3127; border-color: #459661; }
.lobbyTitle { font-size: 15px; font-weight: bold; color: #86efac; }
.lobbySub { font-size: 12px; color: #d6ede0; margin: 2px 0 8px 0; }
.actionRow { display: -webkit-flex; display: flex; margin: 0 -4px; }
.btnPrimary, .btnSecondary {
    -webkit-flex: 1;
    flex: 1;
    margin: 0 4px;
    padding: 11px 10px;
    border-radius: 9px;
    border: 2px solid transparent;
    color: #ffffff;
    font-family: inherit;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
}
.btnPrimary { background: #2b944b; border-color: #86efac; }
.btnSecondary { background: #2c3d4f; border-color: #647c96; }

.questPanel { background: #192924; border-color: #d9a734; cursor: pointer; }
.questHead { margin-bottom: 3px; }
.questTag { display: inline-block; padding: 1px 6px; margin-right: 6px; border-radius: 4px; background: #eab308; color: #16181c; font-size: 10px; font-weight: bold; vertical-align: middle; }
.questTitle { font-size: 13px; color: #fff6d6; vertical-align: middle; }
.questDetail { font-size: 12px; color: #d2e4dc; line-height: 1.3; margin-bottom: 6px; }
.satchelRow { display: -webkit-flex; display: flex; -webkit-align-items: center; align-items: center; }
.hpGroup { -webkit-flex: 1; flex: 1; margin-right: 10px; }
.hpLbl { display: block; font-size: 11px; color: #fca5a5; margin-bottom: 2px; }
.barTrack { height: 8px; border-radius: 4px; background: #0e1613; overflow: hidden; }
.barFill { height: 100%; width: 100%; }
.hpFill { background: #ef4444; }
.satchelMeta { font-family: monospace; font-size: 11px; color: #fde68a; white-space: nowrap; }

.dialoguePanel { background: #18232a; border: 2px solid #f5c344; }
.dlgSpeakerRow { margin-bottom: 4px; }
.dlgSpeaker { font-size: 15px; color: #ffd56b; margin-right: 7px; }
.dlgRole { font-size: 11px; color: #9db8c4; }
.dlgText { font-size: 13px; line-height: 1.4; color: #edf5f8; margin-bottom: 9px; }
.dlgChoiceBtn {
    display: block;
    width: 100%;
    margin-bottom: 6px;
    padding: 11px 12px;
    border-radius: 9px;
    border: 2px solid #59c173;
    background: #1f4d36;
    color: #ffffff;
    font-family: inherit;
    font-size: 14px;
    font-weight: bold;
    text-align: left;
    cursor: pointer;
}
.dlgChoiceBtn:last-child { margin-bottom: 0; }

.journalPanel { background: #19252d; border-color: #7cc4ff; }
.journalTop { display: -webkit-flex; display: flex; -webkit-justify-content: space-between; justify-content: space-between; -webkit-align-items: center; align-items: center; margin-bottom: 6px; color: #ffd56b; }
.miniUtilBtn { padding: 4px 10px; border-radius: 6px; border: 1px solid #6b88a4; background: #263848; color: #ffffff; font-size: 12px; font-weight: bold; cursor: pointer; }
.journalList { font-size: 12px; line-height: 1.38; color: #dce8ee; max-height: 260px; overflow-y: auto; }
.jRow { padding: 5px 4px; border-top: 1px solid rgba(255, 255, 255, 0.08); }
.jRow:first-child { border-top: 0; }
.jQuestRow { display: -webkit-flex; display: flex; -webkit-align-items: center; align-items: center; border-radius: 6px; }
.jQuestRow.jActive { background: rgba(234, 179, 8, 0.14); border: 1px solid #d9a734; margin: 2px 0; }
.jQuestText { -webkit-flex: 1; flex: 1; padding-right: 8px; }
.jQuestSub { font-size: 11px; color: #b7ccd6; margin-top: 2px; }
.jChampRow { background: rgba(180, 83, 9, 0.34); border: 1px solid #facc15; border-radius: 7px; padding: 7px 8px; margin-bottom: 5px; }
.jChampText strong { color: #fde047; }
.jChampBtns { display: -webkit-flex; display: flex; margin-top: 6px; }
.jChampBtns .jTrackBtn { margin-right: 6px; }
.jGoldBtn { background: #d97706 !important; border-color: #fde047 !important; color: #ffffff !important; }
.jTrackBtn {
    -webkit-flex-shrink: 0;
    flex-shrink: 0;
    padding: 6px 10px;
    border-radius: 7px;
    border: 1px solid #7cc4ff;
    background: #1e4b72;
    color: #ffffff;
    font-family: inherit;
    font-size: 12px;
    font-weight: bold;
    cursor: pointer;
}
.jTrackBtn.is-active { background: #eab308; border-color: #fef08a; color: #16181c; }
.jTrackBtn.is-done { background: #1c3a2a; border-color: #4ade80; color: #86efac; }
.jDone { color: #86efac; }

/* Main Play Controls: Analog Joystick + Big Action Buttons */
.playDeck {
    -webkit-flex: 1;
    flex: 1;
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-justify-content: center;
    justify-content: center;
}

.downedBanner, .tetherBanner {
    margin-bottom: 7px;
    padding: 6px 8px;
    border-radius: 7px;
    text-align: center;
    font-size: 11px;
    font-weight: bold;
}
.downedBanner { background: #5c1919; border: 1px solid #f87171; color: #fee2e2; }
.tetherBanner { background: #5a2612; border: 1px solid #fbbf24; color: #fef3c7; }

.controlsRow {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
}

.joyPad {
    -webkit-flex: 1;
    flex: 1;
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: center;
    justify-content: center;
    min-height: 184px;
    touch-action: none;
}

.joyBase {
    position: relative;
    width: 164px;
    height: 164px;
    border-radius: 50%;
    background: #111b17;
    border: 3px solid #486b59;
}
.joyPad.is-active .joyBase { border-color: #86efac; }
.joyAxisH { position: absolute; left: 16px; right: 16px; top: 50%; height: 1px; background: rgba(255, 255, 255, 0.12); }
.joyAxisV { position: absolute; top: 16px; bottom: 16px; left: 50%; width: 1px; background: rgba(255, 255, 255, 0.12); }
.joyDir { position: absolute; font-size: 10px; font-weight: bold; color: #7fa091; }
.joyN { top: 6px; left: 50%; -webkit-transform: translateX(-50%); transform: translateX(-50%); }
.joyS { bottom: 6px; left: 50%; -webkit-transform: translateX(-50%); transform: translateX(-50%); }
.joyW { left: 8px; top: 50%; -webkit-transform: translateY(-50%); transform: translateY(-50%); }
.joyE { right: 8px; top: 50%; -webkit-transform: translateY(-50%); transform: translateY(-50%); }

.joyKnob {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 56px;
    height: 56px;
    margin-left: -28px;
    margin-top: -28px;
    border-radius: 50%;
    background: #ef4444;
    border: 3px solid #ffffff;
}

.btnCol {
    width: 146px;
    margin-left: 10px;
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-flex-shrink: 0;
    flex-shrink: 0;
}

.actBtn {
    width: 100%;
    margin-bottom: 8px;
    padding: 13px 8px;
    border-radius: 12px;
    border: 2px solid transparent;
    color: #ffffff;
    font-family: inherit;
    text-align: center;
    cursor: pointer;
}
.actInteract { background: #268646; border-color: #86efac; }
.actInteract.has-prompt { background: #ca8a04; border-color: #fef08a; }
.actAbility { background: #6d28d9; border-color: #c4b5fd; }
.actAbility.is-cd { background: #374151; border-color: #6b7280; opacity: 0.78; }
.actKicker { display: block; font-size: 9px; font-weight: bold; letter-spacing: 0.8px; color: rgba(255, 255, 255, 0.82); margin-bottom: 2px; }
.actLbl { display: block; font-size: 13px; line-height: 1.2; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }

.subBtnRow { display: -webkit-flex; display: flex; margin: 0 -3px; }
.subBtn {
    -webkit-flex: 1;
    flex: 1;
    margin: 0 3px;
    padding: 9px 4px;
    border-radius: 8px;
    border: 1px solid #486b59;
    background: #22352c;
    color: #e6f5ec;
    font-family: inherit;
    font-size: 12px;
    font-weight: bold;
    cursor: pointer;
}

.utilBar {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
}
.utilBtn {
    margin-right: 6px;
    padding: 6px 10px;
    border-radius: 7px;
    border: 1px solid #486b59;
    background: #1f3129;
    color: #e6f5ec;
    font-family: inherit;
    font-size: 12px;
    font-weight: bold;
    cursor: pointer;
}
.statusHint { -webkit-flex: 1; flex: 1; font-size: 11px; color: #90b2a3; text-align: right; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
